< prev index next >

test/jdk/java/awt/Focus/ModalExcludedWindowClickTest/ModalExcludedWindowClickTest.java

Print this page

        

*** 20,42 **** * or visit www.oracle.com if you need additional information or have any * questions. */ /* ! test @bug 6271849 @summary Tests that component in modal excluded Window which parent is blocked responses to mouse clicks. ! @author anton.tarasov@sun.com: area=awt.focus ! @run applet ModalExcludedWindowClickTest.html */ - import java.applet.Applet; import java.awt.*; import java.awt.event.*; import java.lang.reflect.*; ! public class ModalExcludedWindowClickTest extends Applet { Robot robot; Frame frame = new Frame("Frame"); Window w = new Window(frame); Dialog d = new Dialog ((Dialog)null, "NullParentDialog", true); Button button = new Button("Button"); --- 20,42 ---- * or visit www.oracle.com if you need additional information or have any * questions. */ /* ! @test ! @key headful @bug 6271849 @summary Tests that component in modal excluded Window which parent is blocked responses to mouse clicks. ! @modules java.desktop/sun.awt ! @run main ModalExcludedWindowClickTest */ import java.awt.*; import java.awt.event.*; import java.lang.reflect.*; ! public class ModalExcludedWindowClickTest { Robot robot; Frame frame = new Frame("Frame"); Window w = new Window(frame); Dialog d = new Dialog ((Dialog)null, "NullParentDialog", true); Button button = new Button("Button");
*** 52,65 **** try { robot = new Robot(); } catch (AWTException e) { throw new RuntimeException("Error: unable to create robot", e); } - // Create instructions for the user here, as well as set up - // the environment -- set the layout manager, add buttons, - // etc. - this.setLayout (new BorderLayout ()); } public void start() { if ("sun.awt.motif.MToolkit".equals(Toolkit.getDefaultToolkit().getClass().getName())) { --- 52,61 ----
< prev index next >