mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Emmet: close unclosed tags under transparent command (IDEA-161156)
This commit is contained in:
+3
-2
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2000-2014 JetBrains s.r.o.
|
||||
* Copyright 2000-2016 JetBrains s.r.o.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -23,6 +23,7 @@ import com.intellij.lang.ASTNode;
|
||||
import com.intellij.lang.Language;
|
||||
import com.intellij.lang.xml.XMLLanguage;
|
||||
import com.intellij.openapi.application.ApplicationManager;
|
||||
import com.intellij.openapi.command.CommandProcessor;
|
||||
import com.intellij.openapi.editor.Document;
|
||||
import com.intellij.openapi.fileEditor.FileDocumentManager;
|
||||
import com.intellij.openapi.fileTypes.FileType;
|
||||
@@ -58,7 +59,7 @@ public class XmlZenCodingGeneratorImpl extends XmlZenCodingGenerator {
|
||||
@NotNull PsiElement context) {
|
||||
FileType fileType = context.getContainingFile().getFileType();
|
||||
if (isTrueXml(fileType)) {
|
||||
closeUnclosingTags(tag);
|
||||
CommandProcessor.getInstance().runUndoTransparentAction(() -> closeUnclosingTags(tag));
|
||||
}
|
||||
return tag.getContainingFile().getText();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user