void (final @NotNull EditorMouseListener listener) { assertValid(); EditorMouseListener wrapper = new EditorMouseListener() { @Override public void mousePressed(@NotNull EditorMouseEvent e) { listener.mousePressed(convertEvent(e)); } @Override public void mouseClicked(@NotNull EditorMouseEvent e) { listener.mouseClicked(convertEvent(e)); } @Override public void mouseReleased(@NotNull EditorMouseEvent e) { listener.mouseReleased(convertEvent(e)); } @Override public void mouseEntered(@NotNull EditorMouseEvent e) { listener.mouseEntered(convertEvent(e)); } @Override public void mouseExited(@NotNull EditorMouseEvent e) { listener.mouseExited(convertEvent(e)); } }; myEditorMouseListeners.registerWrapper(listener, wrapper); myDelegate.addEditorMouseListener(wrapper); }