From 69a6dba7ea6d535983afbd31a7b2c71a2f65b72d Mon Sep 17 00:00:00 2001 From: Sergey Malenkov Date: Fri, 3 Nov 2017 01:21:08 +0300 Subject: [PATCH] IDEA-181589 The File Structure in 2017.3.EAP is too condensed when compared with 2017.2.5 --- .../src/com/intellij/ide/util/FileStructurePopup.java | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/platform/lang-impl/src/com/intellij/ide/util/FileStructurePopup.java b/platform/lang-impl/src/com/intellij/ide/util/FileStructurePopup.java index fdfd7f4f9079..ef27ee7263f9 100644 --- a/platform/lang-impl/src/com/intellij/ide/util/FileStructurePopup.java +++ b/platform/lang-impl/src/com/intellij/ide/util/FileStructurePopup.java @@ -371,7 +371,7 @@ public class FileStructurePopup implements Disposable, TreeActionsOwner { rebuildAndSelect(false, myInitialElement).processed(path -> UIUtil.invokeLaterIfNeeded(() -> { TreeUtil.ensureSelection(myTree); - FilteringTreeBuilder.revalidateTree(myTree); + revalidateTree(myTree); myTreeHasBuilt.setDone(); installUpdater(); })); @@ -474,7 +474,7 @@ public class FileStructurePopup implements Disposable, TreeActionsOwner { myTree.expandPath(path); TreeUtil.selectPath(myTree, path); TreeUtil.ensureSelection(myTree); - FilteringTreeBuilder.revalidateTree(myTree); + revalidateTree(myTree); Object userObject = path == null ? null : TreeUtil.getUserObject(path.getLastPathComponent()); if (userObject != null && Comparing.equal(element, unwrapValue(userObject))) { myInitialNodeIsLeaf = myFilteringStructure.getChildElements(userObject).length == 0; @@ -844,7 +844,7 @@ public class FileStructurePopup implements Disposable, TreeActionsOwner { TreeUtil.expand(getTree(), 2); TreeUtil.ensureSelection(myTree); mySpeedSearch.refreshSelection(); - FilteringTreeBuilder.revalidateTree(myTree); + revalidateTree(myTree); result.setResult(p); }))); } @@ -1163,4 +1163,8 @@ public class FileStructurePopup implements Disposable, TreeActionsOwner { return parents; } + private static void revalidateTree(JTree tree) { + tree.revalidate(); + tree.repaint(); + } }