| Summary: | Enhance MVC logo example to provide a palette for object creation. | ||
|---|---|---|---|
| Product: | [Tools] GEF | Reporter: | Alexander Nyßen <nyssen> |
| Component: | GEF MVC | Assignee: | gef-inbox <gef-inbox> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P1 | CC: | cletavernier, ctg, matthias.wienand |
| Version: | 0.2.0 | ||
| Target Milestone: | 4.0.0 (Neon) RC1 | ||
| Hardware: | All | ||
| OS: | All | ||
| Whiteboard: | |||
| Bug Depends on: | 480489, 493617 | ||
| Bug Blocks: | |||
|
Description
Alexander Nyßen
The intended way to realize this would be to have a second FXViewer for the palette, using an JavaFX splitter to arrange both. This approach is currently blocked by bug #480489, as it prevents mouse events from reaching both viewers in such a scenario. I added support for "role-base" adapter injection. This way, we can now defined bindings for several FXViewer instances by using the respective viewer role in the adapter map bindings. Up to now, the mechanism requires that type keys are specified for all adapters that are injected role-based, as we cannot infer their types from the bindings yet. I will try to enhance this, so we have the same 'comfort' for role-based bindings. I added a palette viewer to the MVC Logo example. Per default, the palette is hidden. A palette indicator is anchored to the left of the content viewer. When the indicator is hovered, the palette is opened and elements can be dragged into the content viewer. The changes are published on the master branch. Therfore, I resolve this ticket as fixed for 4.0.0 RC1. The following listing contains all related API changes (removal indicated by "-", addition indicated by "+"). InfiniteCanvas: - protected ScrollBar getHorizontalScrollBar() + public ScrollBar getHorizontalScrollBar() - protected ScrollBar getVerticalScrollBar() + public ScrollBar getVerticalScrollBar() MvcFxModule: + protected void bindContentModelAsContentViewerAdapter(MapBinder) + protected void bindGridModelAsContentViewerAdapter(MapBinder) + protected void bindFXRootPartAsContentViewerAdapter(MapBinder) - protected void bindInsertHandleColor() + protected void bindContentViewerRootPartAdapters(MapBinder) - protected void bindFocusFeedbackColor() - protected void bindFXRootPartAdapters(MapBinder) - protected void bindMoveHandleColor() - protected void bindPrimarySelectionFeedbackColor() - protected void bindSecondarySelectionFeedbackColor() |