boolean (@NotNull ToolWindowManager toolWindowManager) { ToolWindow toolWindow = toolWindowManager.getToolWindow(toolWindowManager.getActiveToolWindowId()); return toolWindow != null && SwingUtilities.isDescendingFrom(myComponent, toolWindow.getComponent()); }