Skip to content

Commit b68af56

Browse files
committed
Fixing style sheet name clash
1 parent cc28ab9 commit b68af56

File tree

10 files changed

+15
-18
lines changed

10 files changed

+15
-18
lines changed

app/save-and-restore/app/src/main/java/org/phoebus/applications/saveandrestore/ui/SaveAndRestoreController.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ public void initialize(URL url, ResourceBundle resourceBundle) {
193193

194194
saveAndRestoreService = SaveAndRestoreService.getInstance();
195195
treeView.getSelectionModel().setSelectionMode(SelectionMode.MULTIPLE);
196-
treeView.getStylesheets().add(getClass().getResource("/style.css").toExternalForm());
196+
treeView.getStylesheets().add(getClass().getResource("/save-and-restore-style.css").toExternalForm());
197197
browserSelectionModel = treeView.getSelectionModel();
198198

199199
ImageView searchButtonImageView = ImageCache.getImageView(SaveAndRestoreApplication.class, "/icons/sar-search.png");

app/save-and-restore/app/src/main/java/org/phoebus/applications/saveandrestore/ui/configuration/ConfigurationFromSelectionController.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ public void initialize(URL location, ResourceBundle resources) {
205205
}
206206
});
207207

208-
configurationNameField.getStylesheets().add(getClass().getResource("/style.css").toExternalForm());
208+
configurationNameField.getStylesheets().add(getClass().getResource("/save-and-restore-style.css").toExternalForm());
209209
configurationNameField.textProperty().addListener((observableValue, oldName, newName) -> {
210210
if (nodeListInFolder.contains(newName)) {
211211
configurationNameField.getStyleClass().add("input-error");

app/save-and-restore/app/src/main/java/org/phoebus/applications/saveandrestore/ui/search/SearchAndFilterViewController.java

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -241,8 +241,9 @@ public SearchAndFilterViewController(SaveAndRestoreController saveAndRestoreCont
241241
@FXML
242242
public void initialize(URL url, ResourceBundle resourceBundle) {
243243

244-
resultTableView.getStylesheets().add(getClass().getResource("/style.css").toExternalForm());
244+
resultTableView.getStylesheets().add(getClass().getResource("/save-and-restore-style.css").toExternalForm());
245245
pagination.getStylesheets().add(this.getClass().getResource("/pagination.css").toExternalForm());
246+
resultTableView.getStylesheets().add(getClass().getResource("/save-and-restore-style.css").toExternalForm());
246247

247248
nodeNameTextField.textProperty().bindBidirectional(nodeNameProperty);
248249
nodeNameTextField.setOnKeyPressed(e -> {
@@ -337,7 +338,7 @@ public void initialize(URL url, ResourceBundle resourceBundle) {
337338
}
338339
);
339340

340-
filterTableView.getStylesheets().add(getClass().getResource("/style.css").toExternalForm());
341+
filterTableView.getStylesheets().add(getClass().getResource("/save-and-restore-style.css").toExternalForm());
341342

342343
filterNameColumn.setCellValueFactory(cell -> new ReadOnlyStringWrapper(cell.getValue().getName()));
343344
filterNameColumn.getStyleClass().add("leftAlignedTableColumnHeader");
@@ -370,9 +371,6 @@ public void initialize(URL url, ResourceBundle resourceBundle) {
370371
saveFilterButton.disableProperty().bind(Bindings.createBooleanBinding(() ->
371372
filterNameProperty.get() == null || filterNameProperty.get().isEmpty(), filterNameProperty));
372373

373-
resultTableView.getStylesheets().add(getClass().getResource("/style.css").toExternalForm());
374-
pagination.getStylesheets().add(this.getClass().getResource("/pagination.css").toExternalForm());
375-
376374
resultTableView.setRowFactory(tableView -> new TableRow<>() {
377375
@Override
378376
protected void updateItem(Node node, boolean empty) {

app/save-and-restore/app/src/main/java/org/phoebus/applications/saveandrestore/ui/search/SearchWindowController.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ public void initialize(URL url, ResourceBundle resourceBundle) {
144144
saveFilterButton.disableProperty().bind(Bindings.createBooleanBinding(() ->
145145
filterNameProperty.get() == null || filterNameProperty.get().isEmpty(), filterNameProperty));
146146

147-
resultTableView.getStylesheets().add(getClass().getResource("/style.css").toExternalForm());
147+
resultTableView.getStylesheets().add(getClass().getResource("/save-and-restore-style.css").toExternalForm());
148148
pagination.getStylesheets().add(this.getClass().getResource("/pagination.css").toExternalForm());
149149

150150
resultTableView.setRowFactory(tableView -> new TableRow<>() {

app/save-and-restore/app/src/main/java/org/phoebus/applications/saveandrestore/ui/snapshot/CompositeSnapshotController.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ public CompositeSnapshotController(CompositeSnapshotTab compositeSnapshotTab, Sa
152152
@FXML
153153
public void initialize() {
154154

155-
snapshotTable.getStylesheets().add(SnapshotTable.class.getResource("/style.css").toExternalForm());
155+
snapshotTable.getStylesheets().add(SnapshotTable.class.getResource("/save-and-restore-style.css").toExternalForm());
156156

157157
saveAndRestoreService = SaveAndRestoreService.getInstance();
158158

app/save-and-restore/app/src/main/java/org/phoebus/applications/saveandrestore/ui/snapshot/RestoreSnapshotController.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@
6464
import org.phoebus.applications.saveandrestore.model.Snapshot;
6565
import org.phoebus.applications.saveandrestore.model.SnapshotData;
6666
import org.phoebus.applications.saveandrestore.model.SnapshotItem;
67-
import org.phoebus.applications.saveandrestore.model.Tag;
6867
import org.phoebus.applications.saveandrestore.model.event.SaveAndRestoreEventReceiver;
6968
import org.phoebus.applications.saveandrestore.ui.SaveAndRestoreService;
7069
import org.phoebus.framework.jobs.JobManager;
@@ -220,14 +219,14 @@ public void initialize() {
220219
thresholdSpinnerValueFactory.setConverter(new DoubleStringConverter());
221220
thresholdSpinner.setValueFactory(thresholdSpinnerValueFactory);
222221
thresholdSpinner.getEditor().setAlignment(Pos.CENTER_RIGHT);
223-
thresholdSpinner.getEditor().getStylesheets().add(getClass().getResource("/style.css").toExternalForm());
222+
thresholdSpinner.getEditor().getStylesheets().add(getClass().getResource("/save-and-restore-style.css").toExternalForm());
224223
thresholdSpinner.getEditor().textProperty().addListener((a, o, n) -> parseAndUpdateThreshold(n));
225224

226225
SpinnerValueFactory<Double> multiplierSpinnerValueFactory = new SpinnerValueFactory.DoubleSpinnerValueFactory(0.0, 999.0, 1.0, 0.01);
227226
multiplierSpinnerValueFactory.setConverter(new DoubleStringConverter());
228227
multiplierSpinner.setValueFactory(multiplierSpinnerValueFactory);
229228
multiplierSpinner.getEditor().setAlignment(Pos.CENTER_RIGHT);
230-
multiplierSpinner.getEditor().getStylesheets().add(getClass().getResource("/style.css").toExternalForm());
229+
multiplierSpinner.getEditor().getStylesheets().add(getClass().getResource("/save-and-restore-style.css").toExternalForm());
231230
multiplierSpinner.getEditor().textProperty()
232231
.addListener((a, o, n) -> {
233232
multiplierSpinner.getEditor().getStyleClass().remove("input-error");

app/save-and-restore/app/src/main/java/org/phoebus/applications/saveandrestore/ui/snapshot/SnapshotTable.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -417,7 +417,7 @@ void setSaved(boolean saved) {
417417
getSelectionModel().setSelectionMode(SelectionMode.MULTIPLE);
418418
setMaxWidth(Double.MAX_VALUE);
419419
setColumnResizePolicy(TableView.CONSTRAINED_RESIZE_POLICY);
420-
getStylesheets().add(SnapshotTable.class.getResource("/style.css").toExternalForm());
420+
getStylesheets().add(SnapshotTable.class.getResource("/save-and-restore-style.css").toExternalForm());
421421

422422
setOnMouseClicked(e -> {
423423
if (getSelectionModel().getSelectedCells() != null && !getSelectionModel().getSelectedCells().isEmpty()) {

app/save-and-restore/app/src/main/java/org/phoebus/applications/saveandrestore/ui/snapshot/SnapshotTreeTable.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -532,7 +532,7 @@ protected void updateItem(TreeTableEntry item, boolean empty) {
532532
setMaxHeight(Double.MAX_VALUE);
533533
VBox.setVgrow(this, Priority.ALWAYS);
534534
setColumnResizePolicy(TreeTableView.CONSTRAINED_RESIZE_POLICY);
535-
getStylesheets().add(SnapshotTreeTable.class.getResource("/style.css").toExternalForm());
535+
getStylesheets().add(SnapshotTreeTable.class.getResource("/save-and-restore-style.css").toExternalForm());
536536

537537
PreferencesReader preferencesReader = new PreferencesReader(SaveAndRestoreApplication.class, "/save_and_restore_preferences.properties");
538538
String parserClassName = preferencesReader.get("treeTableView.hierarchyParser");

app/save-and-restore/app/src/main/java/org/phoebus/applications/saveandrestore/ui/snapshot/tag/TagWidget.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ private static CustomMenuItem getBaseWidget(Image image, String text) {
7171
Label label = new Label(text);
7272

7373
HBox hBox = new HBox();
74-
hBox.getStylesheets().add(SaveAndRestoreApplication.class.getResource("/style.css").toExternalForm());
74+
hBox.getStylesheets().add(SaveAndRestoreApplication.class.getResource("/save-and-restore-style.css").toExternalForm());
7575
hBox.setSpacing(4);
7676
hBox.setAlignment(Pos.CENTER_LEFT);
7777
hBox.getChildren().addAll(imageView, label);
@@ -143,12 +143,12 @@ public static CustomMenuItem TagWithCommentMenuItem(Tag tag) {
143143
tagCreated.setFont(Font.font(Font.getDefault().getSize()*0.9));
144144

145145
VBox vBoxLeft = new VBox();
146-
vBoxLeft.getStylesheets().add(SaveAndRestoreApplication.class.getResource("/style.css").toExternalForm());
146+
vBoxLeft.getStylesheets().add(SaveAndRestoreApplication.class.getResource("/save-and-restore-style.css").toExternalForm());
147147
vBoxLeft.getChildren().addAll(tagName, tagComment);
148148

149149
VBox vBoxRight = new VBox();
150150
vBoxRight.setAlignment(Pos.CENTER_RIGHT);
151-
vBoxRight.getStylesheets().add(SaveAndRestoreApplication.class.getResource("/style.css").toExternalForm());
151+
vBoxRight.getStylesheets().add(SaveAndRestoreApplication.class.getResource("/save-and-restore-style.css").toExternalForm());
152152
vBoxRight.getChildren().addAll(tagCreator, tagCreated);
153153

154154
ImageView trashcanImageView = new ImageView(snapshotTrashcanIcon);
@@ -162,7 +162,7 @@ public static CustomMenuItem TagWithCommentMenuItem(Tag tag) {
162162
HBox.setHgrow(spacer, Priority.ALWAYS);
163163

164164
HBox hBox = new HBox();
165-
hBox.getStylesheets().add(SaveAndRestoreApplication.class.getResource("/style.css").toExternalForm());
165+
hBox.getStylesheets().add(SaveAndRestoreApplication.class.getResource("/save-and-restore-style.css").toExternalForm());
166166
hBox.setAlignment(Pos.CENTER_LEFT);
167167
hBox.setSpacing(4);
168168
hBox.getChildren().addAll(imageView, vBoxLeft, spacer, vBoxRight, trashcanImageView);

app/save-and-restore/app/src/main/resources/style.css renamed to app/save-and-restore/app/src/main/resources/save-and-restore-style.css

File renamed without changes.

0 commit comments

Comments
 (0)