@PersistentProperty public int getBottomTabIndex() { return bottomTabPane.getSelectionModel().getSelectedIndex(); }
if (selectedTab == null && getSkinnable().getSelectionModel().getSelectedIndex() != -1) { getSkinnable().getSelectionModel().select(getSkinnable().getSelectionModel().getSelectedIndex()); selectedTab = getSkinnable().getSelectionModel().getSelectedItem();
private BrowserTab selectedBrowserTab() { return browserMap.get(selectionTab.getSelectedIndex()); }
public void closeTab() { LOGGER.info("Closing Tab..."); if (tabPane.getTabs().size() > 1) { int indexBrowserTab = selectionTab.getSelectedIndex(); browserMap.remove(indexBrowserTab); tabPane.getTabs().remove(selectionTab.getSelectedIndex()); } }
@Override public void run() { applyFilter(columnField.getSelectionModel().getSelectedIndex()-1, tableView, filterField.getText(), regExp.isSelected()); } };
/** * {@inheritDoc} */ @Override public void setupEventHandlers() { comboBox.setOnMouseEntered(event -> toggleTooltip(comboBox)); comboBox.setOnMouseExited(event -> toggleTooltip(comboBox)); comboBox.valueProperty().addListener((observable, oldValue, newValue) -> field.select(comboBox.getSelectionModel().getSelectedIndex())); }
public void openPage(String location) { final URL url; try { url = URLVerifier.verifyURL(location); } catch (MalformedURLException ex) { Logger.getLogger(BrowserFXController.class.getName()).log(Level.SEVERE, null, ex); return; } URLHandler urlHandler = URLHandlersRegistry.getHandler(url); if (urlHandler == null) { return; } Platform.runLater(() -> { URLHandler.Result handleResult = urlHandler.handle(url); if (handleResult.contentDescriptor != ContentDescriptor.NoContent.instance()) { BrowserTab browserTab = TabFactory.newTab(this, locale, handleResult.contentDescriptor); browserTab.getNavigationContext().goTo(url); selectionTab.getSelectedItem().contentProperty().bind(browserTab.contentProperty()); browserMap.put(selectionTab.getSelectedIndex(), browserTab); // if(!urlField.isFocused()){ urlField.textProperty().bind(browserTab.locationProperty()); // } stopButton.disableProperty().set(!browserTab.isStoppable()); selectionTab.getSelectedItem().textProperty().bind(browserTab.titleProperty()); } }); }
tabPane.getSelectionModel().selectedIndexProperty().addListener(tabSelectedIndexChangeListener); int selectedIndex = control.getSelectionModel().getSelectedIndex(); if (selectedIndex < 0 && !control.getDockables().isEmpty()) { selectedIndex = 0; if (selectedIndex >= 0 && selectedIndex != control.getSelectionModel().getSelectedIndex()) { tabPane.getSelectionModel().select(selectedIndex);
tabPane.getSelectionModel().selectedIndexProperty().addListener(tabSelectedIndexChangeListener); int selectedIndex = control.getSelectionModel().getSelectedIndex(); if (selectedIndex < 0 && !control.getDockables().isEmpty()) { selectedIndex = 0; if (selectedIndex >= 0 && selectedIndex != control.getSelectionModel().getSelectedIndex()) { tabPane.getSelectionModel().select(selectedIndex);
if (selectedTab == null && getSkinnable().getSelectionModel().getSelectedIndex() != -1) { getSkinnable().getSelectionModel().select(getSkinnable().getSelectionModel().getSelectedIndex()); selectedTab = getSkinnable().getSelectionModel().getSelectedItem();