mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
KotlinLanguageInjectionSupport: remove calling replaceInjectionsWithUndo on removing of in-place injection
GitOrigin-RevId: 7abee6d0c815b179475e45e814da7d45bb6dcfce
This commit is contained in:
committed by
intellij-monorepo-bot
parent
fd62b42346
commit
396f95abb1
+8
-7
@@ -76,15 +76,16 @@ class KotlinLanguageInjectionSupport : AbstractLanguageInjectionSupport() {
|
||||
|
||||
val project = psiElement.getProject()
|
||||
|
||||
val injectionAnnotation = findAnnotationInjection(psiElement)
|
||||
val injectionComment = findInjectionComment(psiElement)
|
||||
|
||||
val injectInstructions = listOf(injectionAnnotation, injectionComment).filterNotNull()
|
||||
|
||||
val configuration = Configuration.getProjectInstance(project)
|
||||
val injectInstructions = listOfNotNull(
|
||||
findAnnotationInjection(psiElement),
|
||||
findInjectionComment(psiElement)
|
||||
)
|
||||
|
||||
TemporaryPlacesRegistry.getInstance(project).removeHostWithUndo(project, psiElement)
|
||||
configuration.replaceInjectionsWithUndo(project, listOf(), listOf(), injectInstructions)
|
||||
|
||||
project.executeWriteCommand("remove injection in-code instructions") {
|
||||
injectInstructions.forEach(PsiElement::delete)
|
||||
}
|
||||
|
||||
return true
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user