Bug 455495 - Demonstrate creation menu in an FX example snippet, but remove it from MVC.FX and the Logo example.
Summary: Demonstrate creation menu in an FX example snippet, but remove it from MVC.FX...
Status: ASSIGNED
Alias: None
Product: GEF
Classification: Tools
Component: GEF MVC (show other bugs)
Version: unspecified   Edit
Hardware: PC Mac OS X
: P3 normal (vote)
Target Milestone: 3.10.0 (Mars) M7   Edit
Assignee: Matthias Wienand CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-12-17 09:02 EST by Alexander Nyßen CLA
Modified: 2017-01-02 06:35 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Nyßen CLA 2014-12-17 09:02:44 EST
We should generalize org.eclipse.gef4.mvc.fx.example.FXCreationMenuOnClickPolicy into an org.eclipse.gef4.mvc.fx.FXCreateOnClickPolicy, which infers the to be created elements via an adapter.
Comment 1 Alexander Nyßen CLA 2015-02-02 13:43:36 EST
Besides, the creation position does not seem to be calculated precisely. In normal zoom a small offset is visible. If zooming is enabled that offset is enlarged. We need to fix that as well.
Comment 2 Matthias Wienand CLA 2015-04-24 05:34:22 EDT
I generalized the FXCreationMenuOnClickPolicy by introducing an IFXCreationMenuItem interface and querying the menu items via a Provider<List<IFXCreationMenuItem>>>. Moreover, I fixed the creation position (always at the center of the item in the menu) and placed the menu inside of the scrolled region, i.e. it is not a JavaFX Popup anymore.

The code is published on the master branch, therefore I resolve this ticket as fixed for 3.10.0M7.
Comment 3 Matthias Wienand CLA 2016-09-14 04:11:02 EDT
The mechanism should be refactored and the code should be moved to MVC.FX.
Comment 4 Matthias Wienand CLA 2016-12-09 06:58:15 EST
As the
Comment 5 Matthias Wienand CLA 2016-12-09 08:13:17 EST
A context menu should be opened when the user presses the right mouse button. Therefore, showing the creation menu when the right mouse button is pressed is confusing and against the expectations of the user. The creation menu functionality should instead be demonstrated in an FX example snippet. It can probably be included in the Logo example if the creation menu can be accessed via a context menu that is opened when pressing the right mouse button.
Comment 6 Alexander Nyßen CLA 2017-01-02 06:35:54 EST
Moved CreationMenuOnClickPolicy to logo example, so it is no longer considered official API of MVC.FX.