public static @Nullable GuiEditor getActiveEditor(@NotNull DataContext context) {
    FileEditor fileEditor = PlatformDataKeys.LAST_ACTIVE_FILE_EDITOR.getData(context);
    return fileEditor instanceof UIFormEditor ? ((UIFormEditor)fileEditor).getEditor() : null;
  }
public static @Nullable GuiEditor getActiveEditor(@NotNull DataContext context)