2525import de .doubleslash .keeptime .model .StyledMessage ;
2626import de .doubleslash .keeptime .model .Work ;
2727import de .doubleslash .keeptime .rest .integration .heimat .model .HeimatTask ;
28- import de .doubleslash .keeptime .viewpopup .SearchPopup ;
28+ import de .doubleslash .keeptime .viewpopup .SearchCombobox ;
2929import javafx .animation .Animation ;
3030import javafx .animation .KeyFrame ;
3131import javafx .animation .RotateTransition ;
@@ -208,10 +208,10 @@ public void initForDate(LocalDate currentReportDate, List<Work> currentWorkItems
208208 tasksNotInList .setPredicate (predicate );
209209 });
210210
211- SearchPopup <HeimatTask > heimatTaskSearchPopup = new SearchPopup <>(tasksNotInList );
212- heimatTaskSearchPopup .setDisplayTextFunction (task -> task .taskHolderName () + " - " + task .name ());
211+ SearchCombobox <HeimatTask > heimatTaskSearchCombobox = new SearchCombobox <>(tasksNotInList );
212+ heimatTaskSearchCombobox .setDisplayTextFunction (task -> task .taskHolderName () + " - " + task .name ());
213213
214- heimatTaskSearchPopup .setOnItemSelected ((selectedTask , popup ) -> {
214+ heimatTaskSearchCombobox .setOnItemSelected ((selectedTask , popup ) -> {
215215 if (selectedTask == null )
216216 return ;
217217 boolean alreadyExists = items .stream ().anyMatch (row -> row .mapping .heimatTaskId () == selectedTask .id ());
@@ -229,10 +229,10 @@ public void initForDate(LocalDate currentReportDate, List<Work> currentWorkItems
229229 itemsForBindings .add (addedRow ); // add new row also to items2 - as it is not added automatically :(
230230 mappingTableView .scrollTo (items .size () - 1 ); // scroll to newly added row
231231 });
232- heimatTaskSearchPopup .setClearFieldAfterSelection (true );
232+ heimatTaskSearchCombobox .setClearFieldAfterSelection (true );
233233
234- heimatTaskSearchContainer .getChildren ().add (heimatTaskSearchPopup .getComboBox ());
235- HBox .setHgrow (heimatTaskSearchPopup .getComboBox (), Priority .ALWAYS );
234+ heimatTaskSearchContainer .getChildren ().add (heimatTaskSearchCombobox .getComboBox ());
235+ HBox .setHgrow (heimatTaskSearchCombobox .getComboBox (), Priority .ALWAYS );
236236 }
237237
238238 @ FXML
@@ -292,9 +292,6 @@ private HBox createRow(Color color, String text) {
292292 Label label = new Label (text );
293293 label .setTooltip (new Tooltip (text ));
294294
295- label .setMaxWidth (Double .MAX_VALUE );
296- HBox .setHgrow (label , Priority .ALWAYS );
297-
298295 return new HBox (5 , circle , label );
299296 }
300297 });
@@ -454,10 +451,6 @@ protected void updateItem(TableRow item, boolean empty) {
454451 tooltip .setText (statusForTooltip );
455452 }
456453
457- // Fix Cell height not aligning with Textflow
458- // https://stackoverflow.com/questions/42855724/textflow-inside-tablecell-not-correct-cell-height
459- statusFlow .maxWidthProperty ().bind (column .widthProperty ());
460-
461454 setGraphic (new Group (statusFlow ));
462455
463456 setTooltip (tooltip );
0 commit comments