Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 186474

Summary: getDragTracker is not called on contents even when selectable
Product: [Tools] GEF Reporter: Adam Cabler <acabler>
Component: GEF-Legacy GEF (MVC)Assignee: Alexander Nyßen <nyssen>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: nyssen
Version: 3.3   
Target Milestone: 3.7.1 (Indigo) M6   
Hardware: All   
OS: All   
Whiteboard:

Description Adam Cabler CLA 2007-05-10 20:24:18 EDT
From the javadoc and comments in ScalableRootEdit part, getDragTracker shouldn't be called unless the contents part is "neither selector nor opaque".  However, my contents part was selectable, but not opaque and the getDragTracker was never called since the TargetingTool never saw it when calling getTargetEditPart(). This call fell through to the root edit part, which seems almost never right.

/**
 * Should not be called, but returns a MarqeeDragTracker for good measure.
 * @see org.eclipse.gef.EditPart#getDragTracker(org.eclipse.gef.Request)
 */
public DragTracker getDragTracker(Request req) {
	/* 
	 * The root will only be asked for a drag tracker if for some reason the contents
	 * editpart says it is neither selector nor opaque.
	 */
	return new MarqueeDragTracker();
}
Comment 1 Alexander Nyßen CLA 2010-11-12 16:42:43 EST
Is there a way to reproduce this. Does it still hold?
Comment 2 Alexander Nyßen CLA 2011-02-16 14:36:38 EST
Changed comment to indicate the drag tracker is called in case the contents EditPart is not selectable or has a non-opaque figure. Resolving as FIXED.