From d472420805a28213c9179000a9eb4155c91a6fd8 Mon Sep 17 00:00:00 2001 From: Dmitry Date: Sat, 27 Jan 2024 08:58:51 +0100 Subject: [PATCH] project auto open after adding --- .../java/adda/item/root/projectTree/ProjectTreeModel.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/main/java/adda/item/root/projectTree/ProjectTreeModel.java b/src/main/java/adda/item/root/projectTree/ProjectTreeModel.java index 888bc76..b6f4736 100644 --- a/src/main/java/adda/item/root/projectTree/ProjectTreeModel.java +++ b/src/main/java/adda/item/root/projectTree/ProjectTreeModel.java @@ -268,7 +268,10 @@ public void addProject(ProjectTreeNewItemModel newItemModel) { SettingsManager.saveSettings(setting); starDirtWatch(folder); - javax.swing.SwingUtilities.invokeLater(() -> reloadForce()); + javax.swing.SwingUtilities.invokeLater(() -> { + reloadForce(); + setSelectedPath(node); + }); } public void showNewProjectDialog() {