boolean (@NotNull AnActionEvent e, @NotNull XDebuggerTree tree) { List<? extends WatchNodeImpl> nodes = getSelectedNodes(tree, WatchNodeImpl.class); if (nodes.size() == 1) { XDebuggerTreeNode root = tree.getRoot(); if (root instanceof WatchesRootNode) { int firstWatchIndex = ((WatchesRootNode)root).headerNodesCount(); return root.getIndex(nodes.get(0)) > firstWatchIndex; } } return false; }