IDEA-246448 diff: disable new doc renderers in diff viewer
authorAleksey Pivovarov <AMPivovarov@gmail.com>
Mon, 10 Aug 2020 16:46:25 +0000 (19:46 +0300)
committerintellij-monorepo-bot <intellij-monorepo-bot-no-reply@jetbrains.com>
Mon, 10 Aug 2020 18:25:50 +0000 (18:25 +0000)
GitOrigin-RevId: 2d2da0636a426db5dd8497e4613d87ab8123b45d

platform/lang-impl/src/com/intellij/codeInsight/documentation/render/DocRenderManager.java

index f2d020b335bf3c0f0c44e5b6e1fd9bc9109ad31c..727d996cf1927024a3cd72fbe03c97c55ffc11c5 100644 (file)
@@ -5,6 +5,7 @@ import com.intellij.codeInsight.daemon.DaemonCodeAnalyzer;
 import com.intellij.openapi.application.ApplicationManager;
 import com.intellij.openapi.editor.Editor;
 import com.intellij.openapi.editor.EditorFactory;
+import com.intellij.openapi.editor.EditorKind;
 import com.intellij.openapi.editor.ex.EditorSettingsExternalizable;
 import com.intellij.openapi.project.Project;
 import com.intellij.openapi.project.ProjectManager;
@@ -35,6 +36,7 @@ public final class DocRenderManager {
    * @see #setDocRenderingEnabled(Editor, Boolean)
    */
   public static boolean isDocRenderingEnabled(@NotNull Editor editor) {
+    if (editor.getEditorKind() == EditorKind.DIFF) return false;
     Boolean value = editor.getUserData(DOC_RENDER_ENABLED);
     return value == null ? EditorSettingsExternalizable.getInstance().isDocCommentRenderingEnabled() : value;
   }