@Test public void selectSplitPane() { SplitPane splitPane = (SplitPane) getPrimaryStage().getScene().getRoot().lookup(".split-pane"); LoggingRecorder lr = new LoggingRecorder(); Platform.runLater(() -> { RFXSplitPane rfxSplitPane = new RFXSplitPane(splitPane, null, null, lr); splitPane.setDividerPosition(0, 0.6); rfxSplitPane.mouseReleased(null); }); List<Recording> recordings = lr.waitAndGetRecordings(1); Recording recording = recordings.get(0); AssertJUnit.assertEquals("recordSelect", recording.getCall()); AssertJUnit.assertEquals(0.6, new JSONArray((String) recording.getParameters()[0]).getDouble(0)); }
@Override protected void mouseReleased(MouseEvent me) { SplitPane splitPane = (SplitPane) node; String currentDividerLoctions = getDividerLocations(splitPane); if (!currentDividerLoctions.equals(prevLocations)) { recorder.recordSelect(this, currentDividerLoctions); } }
RFXSplitPane extends RFXComponent { @Override protected void mouseReleased(MouseEvent me) { SplitPane splitPane = (SplitPane) node; String currentDividerLoctions = getDividerLocations(splitPane); if (!currentDividerLoctions.equals(prevLocations)) { recorder.recordSelect(this, currentDividerLoctions); } } }
RFXSplitPane extends RFXComponent { @Override protected void mouseReleased(MouseEvent me) { SplitPane splitPane = (SplitPane) node; String currentDividerLoctions = getDividerLocations(splitPane); if (!currentDividerLoctions.equals(prevLocations)) { recorder.recordSelect(this, currentDividerLoctions); } } RFXSplitPane(Node source, JSONOMapConfig omapConfig, Point2D point, IJSONRecorder recorder); }
RFXSplitPane extends RFXComponent { @Override protected void mouseReleased(MouseEvent me) { SplitPane splitPane = (SplitPane) node; String currentDividerLoctions = getDividerLocations(splitPane); if (!currentDividerLoctions.equals(prevLocations)) { recorder.recordSelect(this, currentDividerLoctions); } } RFXSplitPane(Node source, JSONOMapConfig omapConfig, Point2D point, IJSONRecorder recorder); @Override String _getText(); }
RFXSplitPane extends RFXComponent { @Override protected void mouseReleased(MouseEvent me) { SplitPane splitPane = (SplitPane) node; String currentDividerLoctions = getDividerLocations(splitPane); if (!currentDividerLoctions.equals(prevLocations)) { recorder.recordSelect(this, currentDividerLoctions); } } RFXSplitPane(Node source, JSONOMapConfig omapConfig, Point2D point, IJSONRecorder recorder); @Override String _getText(); static final Logger LOGGER; }