From cdc8481e5aab3d15a6bbf7c6a1fe8f91bc234b07 Mon Sep 17 00:00:00 2001 From: brobert Date: Sat, 27 Feb 2016 14:14:18 -0600 Subject: [PATCH] Issue #15: Small UX fixes for batch mode --- .../java/com/adobe/ags/curly/controller/AppController.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/adobe/ags/curly/controller/AppController.java b/src/main/java/com/adobe/ags/curly/controller/AppController.java index 160539c..64d2ad1 100644 --- a/src/main/java/com/adobe/ags/curly/controller/AppController.java +++ b/src/main/java/com/adobe/ags/curly/controller/AppController.java @@ -163,7 +163,11 @@ void singleShotClicked(ActionEvent event) { @FXML void batchStartClicked(ActionEvent event) { ObservableList> selectedItems = FXCollections.observableArrayList(); - highlightedRows.stream().map(batchDataTable.getItems()::get).forEach(selectedItems::add); + if (highlightedRows.isEmpty()) { + selectedItems.addAll(batchDataTable.getItems()); + } else { + highlightedRows.stream().map(batchDataTable.getItems()::get).forEach(selectedItems::add); + } BatchRunner runner = new BatchRunner(loginHandler, concurencyChoice.getValue(), getActions(), selectedItems, defaults, defaults.keySet()); CurlyApp.openActivityMonitor(runner); } @@ -280,7 +284,6 @@ private void loadData(List> data) { }); batchDataTable.setItems(new ObservableListWrapper<>(data)); - batchSize.setText(String.valueOf(data.size())); } int batchSizeValue = 0;