# HG changeset patch # User Claus Gittinger # Date 1403108792 -7200 # Node ID 9a90a9d52bc6edd0cf22f90a6b9677f98dbb8ff7 # Parent bb09c25b54dc2bc9e767f91a782b600701339293 class: UIPainterView changed: #pasteSpecifications:into:beforeIndex:keepLayout:keepPosition:at: diff -r bb09c25b54dc -r 9a90a9d52bc6 UIPainterView.st --- a/UIPainterView.st Wed Jun 18 18:26:22 2014 +0200 +++ b/UIPainterView.st Wed Jun 18 18:26:32 2014 +0200 @@ -485,32 +485,35 @@ beforeIndex notNil ifTrue:[ beforeIndex := beforeIndex + 1 ]. - - (keepPosition and:[ uiPainterAttributes notNil ]) ifTrue:[ - aPointOrNilOrKeep == #keep ifTrue:[ - newOrigin := uiPainterAttributes at:#origin. + eachSpec keepUILayout ifTrue:[ + view layout:eachSpec layout. + ] ifFalse:[ + (keepPosition and:[ uiPainterAttributes notNil ]) ifTrue:[ + aPointOrNilOrKeep == #keep ifTrue:[ + newOrigin := uiPainterAttributes at:#origin. + ] ifFalse:[ + thisAbsOrigin := uiPainterAttributes at:#absOrigin. + + newOrigin := self graphicsDevice + translatePoint:thisAbsOrigin + fromView:self + toView:containerToPasteInto. + ]. ] ifFalse:[ - thisAbsOrigin := uiPainterAttributes at:#absOrigin. - + pastePoint isNil ifTrue:[ pastePoint := 0@0 ]. newOrigin := self graphicsDevice - translatePoint:thisAbsOrigin + translatePoint:pastePoint fromView:self toView:containerToPasteInto. ]. - ] ifFalse:[ - pastePoint isNil ifTrue:[ pastePoint := 0@0 ]. - newOrigin := self graphicsDevice - translatePoint:pastePoint - fromView:self - toView:containerToPasteInto. - ]. - - (bounds containsPoint:newOrigin) ifFalse:[ - newOrigin := pasteOffset asPoint. - pasteOffset := pasteOffset + 4. - ]. - newOrigin notNil ifTrue:[ - self moveObject:view to:newOrigin. + + (bounds containsPoint:newOrigin) ifFalse:[ + newOrigin := pasteOffset asPoint. + pasteOffset := pasteOffset + 4. + ]. + newOrigin notNil ifTrue:[ + self moveObject:view to:newOrigin. + ]. ]. view realized ifFalse:[ view realize.