Skip to main content



      Home
Home » Eclipse Projects » GEF » [GEF4] FXViewer don't work into FX SplitPane.
[GEF4] FXViewer don't work into FX SplitPane. [message #1713236] Mon, 02 November 2015 11:34 Go to next message
Eclipse UserFriend
Trying the new change in FXViewer in GEF4 3.10.1 I had a problem, when I create a FX E4 Application projects I try this:
@PostConstruct
public void postConstruct(BorderPane parent) {
Injector injector = Guice.createInjector(new Module[] { createModule() });
this.domain = ((FXDomain) injector.getInstance(FXDomain.class));
this.viewer = ((FXViewer) this.domain.getAdapter(IViewer.class));

SplitPane splitPane = new SplitPane();
splitPane.orientationProperty().setValue(Orientation.HORIZONTAL);
splitPane.setDividerPositions(0.5f);
splitPane.getItems().addAll(viewer.getScrollPane(), new Text("Testing..."));

parent.setCenter(splitPane);

AbstractZestExample graphExample = new CustomNodeExample();
graph = graphExample.createGraph();

Platform.runLater(() -> {
this.domain.activate();
((ContentModel) viewer.getAdapter(ContentModel.class)).setContents(Collections.singletonList(graph));
});
}
The graph show well but the mouse events don't work, not selection, not drag and drog. I change the SplitPane for a HBox and all is OK, also I change the SplitPane for a ScrollPane and all is OK. In my project I need the SplitPane, please any solution, my English is too bad.
Re: [GEF4] FXViewer don't work into FX SplitPane. [message #1713238 is a reply to message #1713236] Mon, 02 November 2015 11:44 Go to previous messageGo to next message
Eclipse UserFriend
It seems you ran into https://bugs.eclipse.org/bugs/show_bug.cgi?id=480489. The problem is that JavaFX controls will consume the mouse events, so they will not be forwarded to the GEF4 MVC tools. We are working on a solution.
Re: [GEF4] FXViewer don't work into FX SplitPane. [message #1715249 is a reply to message #1713238] Fri, 20 November 2015 09:24 Go to previous message
Eclipse UserFriend
Hi,

I just fixed the bug (https://bugs.eclipse.org/bugs/show_bug.cgi?id=480489) on the master branch and thought I give you a hint here Wink

All events are now forwarded to the gesture callback methods, so that the policies can decide which events to process and which events to disregard.

Best regards,
Matthias
Previous Topic:How to draw draw2D Label vertically
Next Topic:Clipping problem after rotation
Goto Forum:
  


Current Time: Sat Nov 08 14:29:52 EST 2025

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

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

Back to the top