Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » REQ_MOVE and overlapping Layers problem
REQ_MOVE and overlapping Layers problem [message #231560] Sat, 10 March 2007 18:59
Eclipse UserFriend
Originally posted by:

I have a problem with overlapping layers and moving figures within their parentlayer.

I have two Layers which overlap each other completely. Each of these Layers have Figures on them
which may be dragged. Dropping may only occur on their own Layer, ie., they may not be reparented,
only moved within their own parent.

When the DragEditPartsTracker is looking for a target editpart (in updateTargetUnderMouse()) it will
return the first of these Layers it encounters in its search. This may be the wrong layer. This
results in the wrong requests being generated (REQ_ADD instead of REQ_MOVE).

I tried several options:

1. create my own DragEditPartsTracker which in its activate() after calling super.activate() calls
lockTargetEditPart(layerEditPart). This does not work because calling lockTargetEditPart implicitly
initializes the operationSet which can't be done because the DragEditPartsTracker does not have a
viewer yet. That is only set after activation.

2. create my own DragEditPartsTracker with overrides for isMove() and getTargetEditPart(). This
seems to work but looks rather clumsy to me.

I have got the feeling that it could be done a bit simpler. Is that right?


Previous Topic:Palette autohide difficult to turn off
Next Topic:JUnit testing of GEF application
Goto Forum:

Current Time: Sat Nov 27 18:02:38 GMT 2021

Powered by FUDForum. Page generated in 0.01944 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top