diff --git a/platform/platform-api/src/com/intellij/ide/util/treeView/AbstractTreeUi.java b/platform/platform-api/src/com/intellij/ide/util/treeView/AbstractTreeUi.java index 9a3f1341258b..ac21bfad346b 100644 --- a/platform/platform-api/src/com/intellij/ide/util/treeView/AbstractTreeUi.java +++ b/platform/platform-api/src/com/intellij/ide/util/treeView/AbstractTreeUi.java @@ -881,26 +881,31 @@ public class AbstractTreeUi { //todo: to make real callback public ActionCallback queueUpdate(Object element) { - AbstractTreeUpdater updater = getUpdater(); - if (updater == null) { + try { + AbstractTreeUpdater updater = getUpdater(); + if (updater == null) { + return new ActionCallback.Rejected(); + } + + final ActionCallback result = new ActionCallback(); + DefaultMutableTreeNode node = getNodeForElement(element, false); + if (node != null) { + addSubtreeToUpdate(node); + } + else { + addSubtreeToUpdate(getRootNode()); + } + + updater.runAfterUpdate(new Runnable() { + public void run() { + result.setDone(); + } + }); + return result; + } + catch (ProcessCanceledException e) { return new ActionCallback.Rejected(); } - - final ActionCallback result = new ActionCallback(); - DefaultMutableTreeNode node = getNodeForElement(element, false); - if (node != null) { - addSubtreeToUpdate(node); - } - else { - addSubtreeToUpdate(getRootNode()); - } - - updater.runAfterUpdate(new Runnable() { - public void run() { - result.setDone(); - } - }); - return result; } public void doUpdateFromRoot() { diff --git a/platform/platform-api/src/com/intellij/openapi/ui/ShadowAction.java b/platform/platform-api/src/com/intellij/openapi/ui/ShadowAction.java index db763aeae311..3c15887fa8b3 100644 --- a/platform/platform-api/src/com/intellij/openapi/ui/ShadowAction.java +++ b/platform/platform-api/src/com/intellij/openapi/ui/ShadowAction.java @@ -57,6 +57,8 @@ public final class ShadowAction implements Disposable { myComponent = component; myActionId = ActionManager.getInstance().getId(myCopyFromAction); + myAction.getTemplatePresentation().copyFrom(copyFromAction.getTemplatePresentation()); + myKeymapListener = new Keymap.Listener() { public void onShortcutChanged(final String actionId) { if (myActionId == null || actionId.equals(myActionId)) { diff --git a/platform/platform-impl/src/com/intellij/openapi/wm/impl/ToolWindowsPane.java b/platform/platform-impl/src/com/intellij/openapi/wm/impl/ToolWindowsPane.java index 1aac9fbee2a0..da646455f814 100644 --- a/platform/platform-impl/src/com/intellij/openapi/wm/impl/ToolWindowsPane.java +++ b/platform/platform-impl/src/com/intellij/openapi/wm/impl/ToolWindowsPane.java @@ -156,7 +156,8 @@ final class ToolWindowsPane extends JLayeredPane { protected void paintChildren(Graphics g) { super.paintChildren(g); - if (myTopStripe.isVisible() && myStripesOverlayed && UISettings.getInstance().HIDE_TOOL_STRIPES) { + UISettings settings = UISettings.getInstance(); + if (myTopStripe.isVisible() && myStripesOverlayed && settings.HIDE_TOOL_STRIPES) { Dimension topSize = myTopStripe.getSize(); Dimension bottomSize = myBottomStripe.getSize(); Dimension leftSize = myLeftStripe.getSize(); @@ -168,12 +169,18 @@ final class ToolWindowsPane extends JLayeredPane { size.height - topSize.height - bottomSize.height); g.setColor(Color.gray); + + boolean strikeoutTop = settings.SHOW_MAIN_TOOLBAR && !settings.SHOW_NAVIGATION_BAR && topSize.height == 0; + if (topSize.height> 0) { g.drawLine(rec.x, rec.y, rec.x + rec.width, rec.y); } if (leftSize.width > 0) { g.drawLine(rec.x, rec.y, rec.x, rec.y + rec.height); + if (strikeoutTop) { + g.drawLine(0, rec.y, rec.x, rec.y); + } } if (bottomSize.height > 0) { @@ -182,6 +189,9 @@ final class ToolWindowsPane extends JLayeredPane { if (rightSize.width > 0) { g.drawLine(rec.x + rec.width, rec.y, rec.x + rec.width, rec.y + rec.height); + if (strikeoutTop) { + g.drawLine(rec.x + rec.width, rec.y, size.width, rec.y); + } } } }