Skip to content
Snippets Groups Projects
Commit 5c69d7aa authored by Jan Kožusznik's avatar Jan Kožusznik
Browse files

fix: select first active tab in dashboard

parent 8c61403b
No related branches found
No related tags found
No related merge requests found
...@@ -83,6 +83,8 @@ public class JobDetailControl extends TabPane implements CloseableControl, ...@@ -83,6 +83,8 @@ public class JobDetailControl extends TabPane implements CloseableControl,
if (areExecutionDetailsAvailable()) { if (areExecutionDetailsAvailable()) {
enableAllTabs(); enableAllTabs();
} }
setActiveFirstVisibleTab();
} }
// -- CloseableControl methods -- // -- CloseableControl methods --
...@@ -125,4 +127,12 @@ public class JobDetailControl extends TabPane implements CloseableControl, ...@@ -125,4 +127,12 @@ public class JobDetailControl extends TabPane implements CloseableControl,
getTabs().stream().forEach(t -> t.setDisable(false)); getTabs().stream().forEach(t -> t.setDisable(false));
} }
private void setActiveFirstVisibleTab() {
for(Tab t: getTabs()) {
if(!t.isDisable()) {
t.getTabPane().getSelectionModel().select(t);
break;
}
}
}
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment