boolean (@NotNull MouseEvent e, int clickCount) { if (SwingUtilities.isLeftMouseButton(e)) { Object tag = ((SimpleColoredComponent)e.getSource()).getFragmentTagAt(e.getX()); if (tag != null) { if (tag instanceof Consumer consumer) { //noinspection unchecked consumer.accept(e); } else { ((Runnable)tag).run(); } } else { hideCurrentHint(); expand.run(); } return true; } return false; }