Karma auto-rerun tests shouldn't activate Run toolwindow every time

This commit is contained in:
Vassiliy
2014-06-10 12:52:26 +04:00
committed by Sergey Simonchik
parent 880a4db277
commit 56409a938f
2 changed files with 15 additions and 1 deletions
@@ -40,6 +40,7 @@ public class RunContentDescriptor implements Disposable {
private final String myHelpId;
private boolean myActivateToolWindowWhenAdded = true;
private boolean myReuseActivation = false;
private long myExecutionId = 0;
private Computable<JComponent> myFocusComputable = null;
private boolean myAutoFocusContent = false;
@@ -157,6 +158,14 @@ public class RunContentDescriptor implements Disposable {
myActivateToolWindowWhenAdded = activateToolWindowWhenAdded;
}
public boolean isReuseActivation() {
return myReuseActivation;
}
public void setReuseActivation(boolean reuseActivation) {
myReuseActivation = reuseActivation;
}
public long getExecutionId() {
return myExecutionId;
}
@@ -260,7 +260,12 @@ public class RunContentBuilder extends LogConsoleManagerBase {
*/
public RunContentDescriptor showRunContent(final RunContentDescriptor reuseContent) {
final RunContentDescriptor descriptor = createDescriptor();
if(reuseContent != null) descriptor.setAttachedContent(reuseContent.getAttachedContent());
if (reuseContent != null) {
descriptor.setAttachedContent(reuseContent.getAttachedContent());
if (reuseContent.isReuseActivation()) {
descriptor.setActivateToolWindowWhenAdded(reuseContent.isActivateToolWindowWhenAdded());
}
}
return descriptor;
}