Beispiel #1
0
  private void createStatusBar() {
    statusBar = new StatusBar();
    statusBar.setText("Alerts");

    Button alertsButton = new Button();
    alertsButton.textProperty().bind(numberOfAlerts);
    alertsButton.setBackground(
        new Background(new BackgroundFill(Color.ORANGE, new CornerRadii(2), new Insets(4))));
    alertsButton.setOnAction(
        event -> {
          isDetailNodeVisible.setValue(true);
          detailPane.getSelectionModel().select(0);
        });

    statusBar.getLeftItems().add(alertsButton);
    statusBar.progressProperty().bind(webEngine.getLoadWorker().progressProperty());
  }