From ce88af7743e23cc5f10c608b32fb682700e04778 Mon Sep 17 00:00:00 2001 From: develar Date: Wed, 24 Apr 2019 09:50:47 +0200 Subject: [PATCH] always write empty element for tab with index 0 GitOrigin-RevId: f1adf4487e1568dee03d4037b94ef4eddfa6ca95 --- lib/annotations/jdom/org/jdom/annotations.xml | 3 +++ .../intellij/execution/ui/layout/impl/RunnerLayout.java | 8 ++++---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/lib/annotations/jdom/org/jdom/annotations.xml b/lib/annotations/jdom/org/jdom/annotations.xml index 8dfdb34759bf..ce8c20a18e61 100644 --- a/lib/annotations/jdom/org/jdom/annotations.xml +++ b/lib/annotations/jdom/org/jdom/annotations.xml @@ -54,6 +54,9 @@ + + + diff --git a/platform/lang-impl/src/com/intellij/execution/ui/layout/impl/RunnerLayout.java b/platform/lang-impl/src/com/intellij/execution/ui/layout/impl/RunnerLayout.java index 908560f8844a..70a2c78df68c 100644 --- a/platform/lang-impl/src/com/intellij/execution/ui/layout/impl/RunnerLayout.java +++ b/platform/lang-impl/src/com/intellij/execution/ui/layout/impl/RunnerLayout.java @@ -132,15 +132,15 @@ public class RunnerLayout { if (myLightWeightIds != null && myLightWeightIds.contains(eachState.getID())) { continue; } - parentNode.addContent(XmlSerializer.serialize(eachState)); + + Element element = XmlSerializer.serialize(eachState); + parentNode.addContent(element == null ? new Element("ViewImpl") : element); } for (TabImpl eachTab : myTabs) { if (isUsed(eachTab)) { Element element = XmlSerializer.serialize(eachTab); - if (element != null) { - parentNode.addContent(element); - } + parentNode.addContent(element == null ? new Element("TabImpl") : element); } }