< prev index next >

test/javax/swing/JTabbedPane/7024235/Test7024235.java

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

This is a backport of fe58d505fffd from jdk9. 228/596 hunks apply without
modifications. 16 hunks required manual rework. The remainder were for files
not present in jdk8u.


  22  */
  23 
  24 import java.awt.BorderLayout;
  25 import sun.awt.SunToolkit;
  26 
  27 import java.awt.Container;
  28 import java.awt.Rectangle;
  29 import java.awt.Toolkit;
  30 
  31 import javax.swing.JButton;
  32 import javax.swing.JCheckBox;
  33 import javax.swing.JTabbedPane;
  34 
  35 import javax.swing.JFrame;
  36 import javax.swing.SwingUtilities;
  37 import javax.swing.UIManager;
  38 import javax.swing.UIManager.LookAndFeelInfo;
  39 
  40 /*
  41  * @test

  42  * @bug 7024235
  43  * @summary Tests JFrame.pack() with the JTabbedPane
  44  * @author Sergey Malenkov
  45  */
  46 
  47 public class Test7024235 implements Runnable {
  48 
  49     private static final boolean AUTO = null != System.getProperty("test.src", null);
  50 
  51     public static void main(String[] args) throws Exception {
  52         Test7024235 test = new Test7024235();
  53         SunToolkit toolkit = (SunToolkit) Toolkit.getDefaultToolkit();
  54         for (LookAndFeelInfo info : UIManager.getInstalledLookAndFeels()) {
  55             UIManager.setLookAndFeel(info.getClassName());
  56 
  57             test.test();
  58             toolkit.realSync();
  59             Thread.sleep(1000);
  60             test.test();
  61         }




  22  */
  23 
  24 import java.awt.BorderLayout;
  25 import sun.awt.SunToolkit;
  26 
  27 import java.awt.Container;
  28 import java.awt.Rectangle;
  29 import java.awt.Toolkit;
  30 
  31 import javax.swing.JButton;
  32 import javax.swing.JCheckBox;
  33 import javax.swing.JTabbedPane;
  34 
  35 import javax.swing.JFrame;
  36 import javax.swing.SwingUtilities;
  37 import javax.swing.UIManager;
  38 import javax.swing.UIManager.LookAndFeelInfo;
  39 
  40 /*
  41  * @test
  42  * @key headful
  43  * @bug 7024235
  44  * @summary Tests JFrame.pack() with the JTabbedPane
  45  * @author Sergey Malenkov
  46  */
  47 
  48 public class Test7024235 implements Runnable {
  49 
  50     private static final boolean AUTO = null != System.getProperty("test.src", null);
  51 
  52     public static void main(String[] args) throws Exception {
  53         Test7024235 test = new Test7024235();
  54         SunToolkit toolkit = (SunToolkit) Toolkit.getDefaultToolkit();
  55         for (LookAndFeelInfo info : UIManager.getInstalledLookAndFeels()) {
  56             UIManager.setLookAndFeel(info.getClassName());
  57 
  58             test.test();
  59             toolkit.realSync();
  60             Thread.sleep(1000);
  61             test.test();
  62         }


< prev index next >