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

Bug 506738

Summary: Inject support objects (making the support classes adaptable-bound to the viewer where needed)
Product: [Tools] GEF Reporter: Matthias Wienand <matthias.wienand>
Component: GEF MVCAssignee: gef-inbox <gef-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: nyssen
Version: 1.0.0   
Target Milestone: 5.0.0 (Oxygen) RC1   
Hardware: All   
OS: All   
Whiteboard:

Description Matthias Wienand CLA 2016-10-29 11:16:22 EDT
The support classes CursorSupport and SnapSupport are currently instantiated within the policies for which they add supporting functionality. In order to make them easily exchangable, they should be injected as adapters into the viewer via a binding within MvcFxModule. As the support classes need to access the JavaFX Scene or the GridModel, respectively, they should also be adaptable-bound to the viewer in order to access these.
Comment 1 Matthias Wienand CLA 2017-05-18 10:18:42 EDT
I ensured that all support classes are injected into the viewer, from which they are queried by the dependent handlers. The CursorSupport and SnapToSupport need access to the viewer, therefore, they implement IAdaptable.Bound<IViewer>.

The code is published on the master branch, therefore, I resolve this ticket as fixed for 5.0.0 RC1.