@Override
  public void uiDataSnapshot(@NotNull DataSink sink) {
    if (editor.isDisposed()) return;

    sink.set(PlatformDataKeys.COPY_PROVIDER, editor.getCopyProvider());

    if (editor.isRendererMode()) return;

    sink.set(CommonDataKeys.EDITOR, editor);
    sink.set(CommonDataKeys.CARET, editor.getCaretModel().getCurrentCaret());
    sink.set(PlatformDataKeys.DELETE_ELEMENT_PROVIDER, editor.getDeleteProvider());
    sink.set(PlatformDataKeys.CUT_PROVIDER, editor.getCutProvider());
    sink.set(PlatformDataKeys.PASTE_PROVIDER, editor.getPasteProvider());

    LogicalPosition location = editor.myLastMousePressedLocation;
    if (location == null) {
        location = editor.getCaretModel().getLogicalPosition();
    }
    sink.set(CommonDataKeys.EDITOR_VIRTUAL_SPACE, EditorCoreUtil.inVirtualSpace(editor, location));
    Point point = editor.myLastMousePressedPoint;
    if (point != null) {
      sink.set(PlatformDataKeys.EDITOR_CLICK_OVER_TEXT, EditorUtil.isPointOverText(editor, point));
    }
  }
@Override
  public void uiDataSnapshot(@NotNull DataSink sink)