8166015: [PIT][TEST_BUG] stray character in java/awt/Focus/ModalDialogActivationTest/ModalDialogActivationTest.java
authorarapte
Tue, 20 Sep 2016 12:37:54 +0530
changeset 41390 a50c1f9c2244
parent 41389 21cd852c2b60
child 41391 fdd0ab85d1c1
8166015: [PIT][TEST_BUG] stray character in java/awt/Focus/ModalDialogActivationTest/ModalDialogActivationTest.java Reviewed-by: aghaisas, ssadetsky
jdk/test/java/awt/Focus/ModalDialogActivationTest/ModalDialogActivationTest.java
--- a/jdk/test/java/awt/Focus/ModalDialogActivationTest/ModalDialogActivationTest.java	Tue Sep 20 11:46:34 2016 +0530
+++ b/jdk/test/java/awt/Focus/ModalDialogActivationTest/ModalDialogActivationTest.java	Tue Sep 20 12:37:54 2016 +0530
@@ -23,15 +23,21 @@
  * questions.
  */
 
-import javax.swing.*;
-import java.awt.*;
-import java.awt.event.*;
+import java.awt.EventQueue;
+import java.awt.Frame;
+import java.awt.event.WindowAdapter;
+import java.awt.event.WindowEvent;
+import javax.swing.JDialog;
+import javax.swing.JFrame;
 
 /*
   @test
-  @bug       8160570
-  @summary   Tests that a modal dialog receives WINDOW_ACTIVATED & WINDOW_GAINED_FOCUS on first show.
+  @key headful
+  @bug 8160570 8166015
+  @summary Tests that a modal dialog receives WINDOW_ACTIVATED
+            & WINDOW_GAINED_FOCUS on first show.
 */
+
 public class ModalDialogActivationTest {
     static final Object lock = new Object();
     static volatile boolean activated;
@@ -48,7 +54,8 @@
             }
         }
         if (!activated || !focused) {
-            throw new RuntimeException("Test FAILED: activated: " + activated + ", focused: " + focused);
+            throw new RuntimeException("Test FAILED: activated: " + activated
+                                        + ", focused: " + focused);
         }
         System.out.println("Test PASSED");
     }
@@ -79,7 +86,7 @@
     }
 
     static class MyModalDialog extends JDialog {
-        public MyModalDialog(Frame owner, String title)ยช {
+        public MyModalDialog(Frame owner, String title) {
             super(owner, title, true);
         }