From c06ebb76f5ba7d37e4f154dc57568c6b28412eed Mon Sep 17 00:00:00 2001 From: Thomas Schouten Date: Thu, 12 Dec 2024 20:10:20 +0100 Subject: [PATCH] Ignore Qodana warnings --- .../editor/postfix/LatexStringBasedPostfixTemplates.kt | 2 ++ .../editor/postfix/editable/LatexEditablePostfixTemplate.kt | 1 + src/nl/hannahsten/texifyidea/gutter/LatexCompileGutter.kt | 3 ++- 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/nl/hannahsten/texifyidea/editor/postfix/LatexStringBasedPostfixTemplates.kt b/src/nl/hannahsten/texifyidea/editor/postfix/LatexStringBasedPostfixTemplates.kt index f8361c6f5..40f23e270 100644 --- a/src/nl/hannahsten/texifyidea/editor/postfix/LatexStringBasedPostfixTemplates.kt +++ b/src/nl/hannahsten/texifyidea/editor/postfix/LatexStringBasedPostfixTemplates.kt @@ -63,6 +63,8 @@ internal object LatexWrapWithMathbbPostfixTemplate : LatexWrapWithCommandPostfix internal object LatexWrapWithBmPostfixTemplate : LatexWrapWithCommandPostfixTemplate("bm", mathOnly = true, pack = LatexPackage.BM) internal object LatexWrapWithMathcalPostfixTemplate : LatexWrapWithCommandPostfixTemplate("mathcal", name = "cal", mathOnly = true) +// Not actually a postfix template, just a base class +@Suppress("PostfixTemplateDescriptionNotFound") internal open class LatexWrapWithCommandPostfixTemplate(commandName: String, name: String = commandName, mathOnly: Boolean = false, textOnly: Boolean = false, pack: LatexPackage? = null) : ConstantStringBasedPostfixTemplate( name, "\\$commandName{expr}", diff --git a/src/nl/hannahsten/texifyidea/editor/postfix/editable/LatexEditablePostfixTemplate.kt b/src/nl/hannahsten/texifyidea/editor/postfix/editable/LatexEditablePostfixTemplate.kt index 0499efd4d..885fdf414 100644 --- a/src/nl/hannahsten/texifyidea/editor/postfix/editable/LatexEditablePostfixTemplate.kt +++ b/src/nl/hannahsten/texifyidea/editor/postfix/editable/LatexEditablePostfixTemplate.kt @@ -7,6 +7,7 @@ import com.intellij.psi.PsiElement import nl.hannahsten.texifyidea.editor.postfix.LatexPostFixTemplateProvider import nl.hannahsten.texifyidea.editor.postfix.LatexPostfixExpressionSelector +@Suppress("PostfixTemplateDescriptionNotFound") class LatexEditablePostfixTemplate(templateId: String, templateName: String, template: TemplateImpl, conditions: Set, provider: LatexPostFixTemplateProvider) : EditablePostfixTemplateWithMultipleExpressions(templateId, templateName, template, "", conditions, true, provider) { diff --git a/src/nl/hannahsten/texifyidea/gutter/LatexCompileGutter.kt b/src/nl/hannahsten/texifyidea/gutter/LatexCompileGutter.kt index 316a04eec..8ea8863ed 100644 --- a/src/nl/hannahsten/texifyidea/gutter/LatexCompileGutter.kt +++ b/src/nl/hannahsten/texifyidea/gutter/LatexCompileGutter.kt @@ -3,6 +3,7 @@ package nl.hannahsten.texifyidea.gutter import com.intellij.execution.lineMarker.ExecutorAction import com.intellij.execution.lineMarker.RunLineMarkerContributor import com.intellij.openapi.actionSystem.ActionManager +import com.intellij.openapi.actionSystem.IdeActions import com.intellij.psi.PsiElement import nl.hannahsten.texifyidea.TexifyIcons import nl.hannahsten.texifyidea.psi.LatexBeginCommand @@ -29,7 +30,7 @@ class LatexCompileGutter : RunLineMarkerContributor() { // Lookup actions. val actionManager = ActionManager.getInstance() - val editConfigs = actionManager.getAction("editRunConfigurations") + val editConfigs = actionManager.getAction(IdeActions.ACTION_EDIT_RUN_CONFIGURATIONS) val actions = ExecutorAction.getActions(0) // Create icon.