@FXML private void initialize() { deleteButton.setDisable(true); reconcileButton.setDisable(true); initializeTreeTableView(); Platform.runLater(this::loadAccountTree); MessageBus.getInstance() .registerListener( this, MessageChannel.SYSTEM, MessageChannel.ACCOUNT, MessageChannel.TRANSACTION); // Register invalidation listeners to force a reload typeFilter.addListener(observable -> reload()); selectedAccountProperty.addListener( (observable, oldValue, newValue) -> { updateButtonStates(); }); modifyButton.disableProperty().bind(selectedAccountProperty.isNull()); AccountBalanceDisplayManager.getAccountBalanceDisplayModeProperty() .addListener( (observable, oldValue, newValue) -> { treeTableView.refresh(); }); }
public void setAccountTypeFilter(final AccountTypeFilter filter) { // Bind the buttons to the filter bankAccountCheckBox .selectedProperty() .bindBidirectional(filter.getAccountTypesVisibleProperty()); incomeAccountCheckBox .selectedProperty() .bindBidirectional(filter.getIncomeTypesVisibleProperty()); expenseAccountCheckBox .selectedProperty() .bindBidirectional(filter.getExpenseTypesVisibleProperty()); hiddenAccountCheckBox .selectedProperty() .bindBidirectional(filter.getHiddenTypesVisibleProperty()); }