< prev index next >

test/javax/swing/JPopupMenu/6415145/bug6415145.java

Print this page
rev 14989 : 8160974: [TESTBUG] Mark more headful tests with @key headful.


   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.
   8  *
   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  */
  23 /*
  24 @test
  25 @bug 6415145
  26 @summary REGRESSION: Selected item is not being updated while dragging above popup menu
  27 @library ../../../../lib/testlibrary
  28 @build ExtendedRobot
  29 @author Mikhail Lapshin
  30 @run main bug6415145
  31 */

  32 
  33 import javax.swing.*;
  34 import java.awt.event.*;
  35 import java.awt.AWTException;
  36 import java.awt.Component;
  37 
  38 public class bug6415145 {
  39     private JFrame frame;
  40     private JButton button;
  41     private JPopupMenu popupMenu;
  42     private JMenuItem item1;
  43     private JMenuItem item2;
  44     private static ExtendedRobot robot;
  45 
  46     public static void main(String[] args) throws Exception {
  47         robot = new ExtendedRobot();
  48         final bug6415145 bugTest = new bug6415145();
  49         try {
  50             SwingUtilities.invokeAndWait(new Runnable() {
  51                 public void run() {




   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.
   8  *
   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  */
  23 /*
  24  * @test
  25  * @key headful
  26  * @bug 6415145
  27  * @summary REGRESSION: Selected item is not being updated while dragging above popup menu
  28  * @library ../../../../lib/testlibrary
  29  * @build ExtendedRobot
  30  * @author Mikhail Lapshin
  31  * @run main bug6415145
  32  */
  33 
  34 import javax.swing.*;
  35 import java.awt.event.*;
  36 import java.awt.AWTException;
  37 import java.awt.Component;
  38 
  39 public class bug6415145 {
  40     private JFrame frame;
  41     private JButton button;
  42     private JPopupMenu popupMenu;
  43     private JMenuItem item1;
  44     private JMenuItem item2;
  45     private static ExtendedRobot robot;
  46 
  47     public static void main(String[] args) throws Exception {
  48         robot = new ExtendedRobot();
  49         final bug6415145 bugTest = new bug6415145();
  50         try {
  51             SwingUtilities.invokeAndWait(new Runnable() {
  52                 public void run() {


< prev index next >