From aaab9175dd27c0c681c2bd8f444852989b2127db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Yann=20C=C3=A9bron?= Date: Thu, 10 Oct 2024 16:33:37 +0200 Subject: [PATCH] [devkit] ToggleHighlightingMarkupAction: DumbAware GitOrigin-RevId: 376cc796b269a44e4f296979cfaf536e89feffac --- .../src/actions/ToggleHighlightingMarkupAction.java | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/plugins/devkit/devkit-core/src/actions/ToggleHighlightingMarkupAction.java b/plugins/devkit/devkit-core/src/actions/ToggleHighlightingMarkupAction.java index e8c55daa20d6..418b736f8b38 100644 --- a/plugins/devkit/devkit-core/src/actions/ToggleHighlightingMarkupAction.java +++ b/plugins/devkit/devkit-core/src/actions/ToggleHighlightingMarkupAction.java @@ -1,11 +1,10 @@ -// Copyright 2000-2022 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. +// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. package org.jetbrains.idea.devkit.actions; import com.intellij.codeInsight.daemon.impl.DaemonCodeAnalyzerEx; import com.intellij.codeInsight.daemon.impl.HighlightInfo; import com.intellij.lang.annotation.HighlightSeverity; import com.intellij.openapi.actionSystem.ActionUpdateThread; -import com.intellij.openapi.actionSystem.AnAction; import com.intellij.openapi.actionSystem.AnActionEvent; import com.intellij.openapi.actionSystem.CommonDataKeys; import com.intellij.openapi.application.WriteAction; @@ -16,6 +15,7 @@ import com.intellij.openapi.command.UndoConfirmationPolicy; import com.intellij.openapi.editor.Document; import com.intellij.openapi.editor.Editor; import com.intellij.openapi.editor.ex.util.EditorUtil; +import com.intellij.openapi.project.DumbAwareAction; import com.intellij.openapi.project.Project; import com.intellij.openapi.util.TextRange; import com.intellij.psi.PsiFile; @@ -31,7 +31,7 @@ import java.util.regex.Pattern; /** * @author gregsh */ -public class ToggleHighlightingMarkupAction extends AnAction { +public class ToggleHighlightingMarkupAction extends DumbAwareAction { @Override public void update(@NotNull AnActionEvent e) { Editor editor = e.getData(CommonDataKeys.EDITOR); @@ -197,7 +197,6 @@ public class ToggleHighlightingMarkupAction extends AnAction { } if (opening) { sb.append(" descr=\"").append(cur.getDescription()).append("\""); - } sb.append(">"); }