/** * Constructor */ public NavigationBar() { super(); IconUtils.setHeaderNavigationBack(backIcon); backIcon.getStyleClass().addAll("transparent-focus", "empty-padding", "scale-down-on-click"); backIcon.setOnAction(e -> goBack()); pane.getChildren().addAll(location0, location1, backIcon); getChildren().add(pane); NodeHelper.setHVGrow(pane); getStyleClass().add("ep-header-center-area-nav-bar-container"); location0.getStyleClass().add("previous-location-item-label"); location1.getStyleClass().add("current-location-item-label"); backIcon.setLayoutX(16); backIcon.setLayoutY(15); location0.setLayoutX(46); location0.setLayoutY(18); location1.setLayoutX(22); location1.setLayoutY(65); }
/** * Constructor */ public SingleLocationNavigationBar() { super(); IconUtils.setHeaderNavigationBack(backIcon); backIcon.setOnAction(e -> goBack()); backIcon.getStyleClass().addAll("app-header-button", "simple-button"); backIcon.managedProperty().bind(backIcon.visibleProperty()); backIcon.setDisable(true); getChildren().addAll(backIcon, locationContainer); getStyleClass().add("ep-primary-menu-with-navbar-top-toolbar"); getStyleClass().add("ep-primary-menu-with-navbar-toolbar"); managedProperty().bind(visibleProperty()); }
/** * Constructor */ public SingleLocationPrimaryMenuWithNavigationBar() { super(); IconUtils.setHeaderNavigationBack(backIcon); backIcon.setOnAction(e -> goBack()); backIcon.getStyleClass().remove("jfx-button"); backIcon.getStyleClass().remove("button"); backIcon.managedProperty().bind(backIcon.visibleProperty()); backIcon.setVisible(false); final HBox box = NodeHelper.wrapInHbox(backIcon); box.getStyleClass().add("ep-navbar-top-toolbar-back-icon-container"); topToolbar.getChildren().addAll(box, locationContainer); getChildren().addAll(topToolbar, bottomToolbar); topToolbar.getStyleClass().add("ep-primary-menu-with-navbar-top-toolbar"); bottomToolbar.getStyleClass().add("ep-primary-menu-with-navbar-bottom-toolbar"); getStyleClass().add("ep-primary-menu-with-navbar-toolbar"); // location0.getStyleClass().add("current-location-item-label"); topToolbar.minWidthProperty().bind(topToolbar.prefWidthProperty()); topToolbar.minHeightProperty().bind(topToolbar.prefHeightProperty()); topToolbar.maxHeightProperty().bind(topToolbar.prefHeightProperty()); bottomToolbar.minWidthProperty().bind(bottomToolbar.prefWidthProperty()); bottomToolbar.minHeightProperty().bind(bottomToolbar.prefHeightProperty()); bottomToolbar.maxHeightProperty().bind(bottomToolbar.prefHeightProperty()); bottomToolbar.managedProperty().bind(bottomToolbar.visibleProperty()); NodeHelper.setHVGrow(topToolbar, bottomToolbar, this); bottomToolbar.setVisible(false); }
/** * @{inheritedDoc} */ @Override public void buildFrom(IEmaginController controller, VLViewComponentXML configuration) { this.controller = (AbstractViewController) controller; backIcon = new Button(); backIcon.setOnAction(e -> goBack()); IconUtils.setHeaderNavigationBack(backIcon); backIcon.getStyleClass().addAll("ep-headerless-app-header-button", "hand-hover"); backIcon.setDisable(true); backIcon.setVisible(true); backIcon.setContentDisplay(ContentDisplay.GRAPHIC_ONLY); backIcon.setAlignment(Pos.CENTER); getChildren().addAll(backIcon); getStyleClass().addAll("hand-hover"); //getStyleClass().add("ep-primary-menu-with-navbar-top-toolbar"); //getStyleClass().add("ep-primary-menu-with-navbar-toolbar"); setAlignment(Pos.CENTER); setMinHeight(54); addEventFilter(MouseEvent.MOUSE_CLICKED, e->{ }); }
/** * Constructor */ public PrimaryMenuWithNavigationBar() { super(); IconUtils.setHeaderNavigationBack(backIcon); backIcon.setOnAction(e -> goBack()); backIcon.getStyleClass().addAll("app-header-button", "hand-hover"); backIcon.managedProperty().bind(backIcon.visibleProperty()); // TO DO HANDLE PREVIOUS AND CURRENT previousLocation.managedProperty().bind(previousLocation.visibleProperty()); previousLocation.setVisible(false); topToolbar.getChildren().addAll(backIcon, currentLocation); bottomToolbar.getChildren().add(previousLocation); getChildren().addAll(topToolbar, bottomToolbar); topToolbar.getStyleClass().add("ep-primary-menu-with-navbar-top-toolbar"); bottomToolbar.getStyleClass().add("ep-primary-menu-with-navbar-bottom-toolbar"); getStyleClass().add("ep-primary-menu-with-navbar-toolbar"); topToolbar.minWidthProperty().bind(topToolbar.prefWidthProperty()); // topToolbar.maxWidthProperty().bind(topToolbar.prefWidthProperty()); topToolbar.minHeightProperty().bind(topToolbar.prefHeightProperty()); topToolbar.maxHeightProperty().bind(topToolbar.prefHeightProperty()); bottomToolbar.minWidthProperty().bind(bottomToolbar.prefWidthProperty()); // bottomToolbar.maxWidthProperty().bind(bottomToolbar.prefWidthProperty()); bottomToolbar.minHeightProperty().bind(bottomToolbar.prefHeightProperty()); bottomToolbar.maxHeightProperty().bind(bottomToolbar.prefHeightProperty()); bottomToolbar.managedProperty().bind(bottomToolbar.visibleProperty()); NodeHelper.setHVGrow(topToolbar, bottomToolbar, this); bottomToolbar.setVisible(false); }