From 332a5c52fef908341d4e3c0390ebfa8e070ad37c Mon Sep 17 00:00:00 2001 From: Jamie Shiell Date: Sun, 15 Jan 2023 15:51:03 +0000 Subject: [PATCH] Set target component on toolbars (#602). --- CHANGELOG.md | 1 + .../idea/checkstyle/toolwindow/CheckStyleToolWindowPanel.java | 2 ++ src/main/resources/META-INF/plugin.xml | 1 + 3 files changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0674ba4e..1d9c6f89 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,7 @@ # CheckStyle-IDEA Changelog +* **5.75.0** Fixed: Set target component on toolbars (#602). * **5.75.0** New: Added Checkstyle 10.6.0. * **5.74.1** Fixed: Ensure scope is checked as read action (#595). * **5.74.0** New: Added Checkstyle 10.5.0 - thanks to @kennysoft (#596). diff --git a/src/main/java/org/infernus/idea/checkstyle/toolwindow/CheckStyleToolWindowPanel.java b/src/main/java/org/infernus/idea/checkstyle/toolwindow/CheckStyleToolWindowPanel.java index 4db4007c..4a23c3b8 100644 --- a/src/main/java/org/infernus/idea/checkstyle/toolwindow/CheckStyleToolWindowPanel.java +++ b/src/main/java/org/infernus/idea/checkstyle/toolwindow/CheckStyleToolWindowPanel.java @@ -117,11 +117,13 @@ public CheckStyleToolWindowPanel(final ToolWindow toolWindow, final Project proj ActionManager.getInstance().getAction(MAIN_ACTION_GROUP); final ActionToolbar mainToolbar = ActionManager.getInstance().createActionToolbar( ID_TOOLWINDOW, mainActionGroup, false); + mainToolbar.setTargetComponent(this); final ActionGroup treeActionGroup = (ActionGroup) ActionManager.getInstance().getAction(TREE_ACTION_GROUP); final ActionToolbar treeToolbar = ActionManager.getInstance().createActionToolbar( ID_TOOLWINDOW, treeActionGroup, false); + treeToolbar.setTargetComponent(this); final Box toolBarBox = Box.createHorizontalBox(); toolBarBox.add(mainToolbar.getComponent()); diff --git a/src/main/resources/META-INF/plugin.xml b/src/main/resources/META-INF/plugin.xml index 27d9d536..d0c8c525 100644 --- a/src/main/resources/META-INF/plugin.xml +++ b/src/main/resources/META-INF/plugin.xml @@ -24,6 +24,7 @@ +
  • 5.75.0: Fixed: Set target component on toolbars (#602).
  • 5.75.0: New: Added Checkstyle 10.6.0.
  • 5.74.1: Fixed: Ensure scope is checked as read action (#595).
  • 5.74.0: New: Added Checkstyle 10.5.0 - thanks to @kennysoft (#596).