Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarkus Keller2015-01-19 12:57:18 +0000
committerMarkus Keller2015-01-19 12:57:18 +0000
commit058694a2fadc002a78b472c249d6a923c09e332f (patch)
tree0e1b563d13da64b21d36bb61bc93a62298a839ff /org.eclipse.ui.workbench.texteditor.tests
parenta8b5c9d223db683911d633ccb68302fd29adf2c3 (diff)
downloadeclipse.platform.text-058694a2fadc002a78b472c249d6a923c09e332f.tar.gz
eclipse.platform.text-058694a2fadc002a78b472c249d6a923c09e332f.tar.xz
eclipse.platform.text-058694a2fadc002a78b472c249d6a923c09e332f.zip
more logging: active Shell, explicit "null!" for getFocusControl()I20150120-0800
Diffstat (limited to 'org.eclipse.ui.workbench.texteditor.tests')
-rw-r--r--org.eclipse.ui.workbench.texteditor.tests/src/org/eclipse/ui/workbench/texteditor/tests/ScreenshotTest.java11
1 files changed, 7 insertions, 4 deletions
diff --git a/org.eclipse.ui.workbench.texteditor.tests/src/org/eclipse/ui/workbench/texteditor/tests/ScreenshotTest.java b/org.eclipse.ui.workbench.texteditor.tests/src/org/eclipse/ui/workbench/texteditor/tests/ScreenshotTest.java
index a3e778455..58ce28626 100644
--- a/org.eclipse.ui.workbench.texteditor.tests/src/org/eclipse/ui/workbench/texteditor/tests/ScreenshotTest.java
+++ b/org.eclipse.ui.workbench.texteditor.tests/src/org/eclipse/ui/workbench/texteditor/tests/ScreenshotTest.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2012, 2014 IBM Corporation and others.
+ * Copyright (c) 2012, 2015 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@@ -119,8 +119,10 @@ public class ScreenshotTest extends TestCase {
// Dump focus control, parents, and shells:
Control focusControl = display.getFocusControl();
- if (focusControl != null) {
- out.println("FocusControl: ");
+ out.println("FocusControl: ");
+ if (focusControl == null) {
+ System.out.println(" null!");
+ } else {
StringBuffer indent = new StringBuffer(" ");
do {
out.println(indent.toString() + focusControl);
@@ -133,7 +135,8 @@ public class ScreenshotTest extends TestCase {
out.println("Shells: ");
for (int i = 0; i < shells.length; i++) {
Shell shell = shells[i];
- out.print((shell.isVisible() ? " visible: " : " invisible: ") + shell);
+ out.print(display.getActiveShell() == shell ? " active, " : " inactive, ");
+ out.print((shell.isVisible() ? "visible: " : "invisible: ") + shell);
out.println(" @ " + shell.getBounds().toString());
}
}

Back to the top