author | serb |
Wed, 28 Oct 2015 15:41:42 +0300 | |
changeset 33854 | e89a68072d5b |
permissions | -rw-r--r-- |
33854
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
1 |
/* |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
2 |
* Copyright (c) 2005, 2015, Oracle and/or its affiliates. All rights reserved. |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
3 |
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
4 |
* |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
5 |
* This code is free software; you can redistribute it and/or modify it |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
6 |
* under the terms of the GNU General Public License version 2 only, as |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
7 |
* published by the Free Software Foundation. |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
8 |
* |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
9 |
* This code is distributed in the hope that it will be useful, but WITHOUT |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
10 |
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
11 |
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
12 |
* version 2 for more details (a copy is included in the LICENSE file that |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
13 |
* accompanied this code). |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
14 |
* |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
15 |
* You should have received a copy of the GNU General Public License version |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
16 |
* 2 along with this work; if not, write to the Free Software Foundation, |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
17 |
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
18 |
* |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
19 |
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
20 |
* or visit www.oracle.com if you need additional information or have any |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
21 |
* questions. |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
22 |
*/ |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
23 |
|
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
24 |
import java.awt.Graphics; |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
25 |
import java.awt.image.BufferedImage; |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
26 |
import java.util.concurrent.CyclicBarrier; |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
27 |
|
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
28 |
import javax.swing.JButton; |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
29 |
import javax.swing.SwingUtilities; |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
30 |
import javax.swing.UIManager; |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
31 |
import javax.swing.UnsupportedLookAndFeelException; |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
32 |
|
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
33 |
import sun.awt.AppContext; |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
34 |
import sun.awt.SunToolkit; |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
35 |
|
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
36 |
import static javax.swing.UIManager.getInstalledLookAndFeels; |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
37 |
|
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
38 |
/** |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
39 |
* @test |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
40 |
* @bug 6190373 |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
41 |
* @summary Tests 6190373 |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
42 |
* @author Scott Violet |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
43 |
* @modules java.desktop/sun.awt |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
44 |
*/ |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
45 |
public final class bug6190373 { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
46 |
|
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
47 |
private static AppContext app1; |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
48 |
private static AppContext app2; |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
49 |
private static final int LOOP_COUNT = 10000; |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
50 |
private static final CyclicBarrier barrier = new CyclicBarrier(2); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
51 |
|
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
52 |
public static void main(final String[] args) throws Exception { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
53 |
final Thread t1 = new Thread(new ThreadGroup("firstGroup"), () -> { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
54 |
app1 = SunToolkit.createNewAppContext(); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
55 |
test(true); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
56 |
}); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
57 |
final Thread t2 = new Thread(new ThreadGroup("secondGroup"), () -> { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
58 |
app2 = SunToolkit.createNewAppContext(); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
59 |
test(false); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
60 |
}); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
61 |
|
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
62 |
t1.start(); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
63 |
t2.start(); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
64 |
t1.join(); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
65 |
t2.join(); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
66 |
app1.dispose(); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
67 |
app2.dispose(); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
68 |
} |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
69 |
|
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
70 |
private static void test(final boolean lock) { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
71 |
for (final UIManager.LookAndFeelInfo laf : getInstalledLookAndFeels()) { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
72 |
try { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
73 |
SwingUtilities.invokeAndWait(() -> setLookAndFeel(laf)); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
74 |
barrier.await(); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
75 |
SwingUtilities.invokeAndWait(() -> slam(lock)); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
76 |
barrier.await(); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
77 |
} catch (final Exception e) { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
78 |
throw new RuntimeException(e); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
79 |
} |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
80 |
} |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
81 |
} |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
82 |
|
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
83 |
private static void slam(final boolean lock) { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
84 |
JButton button = new JButton("HI"); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
85 |
button.setSize(100, 100); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
86 |
BufferedImage image = new BufferedImage(100, 100, |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
87 |
BufferedImage.TYPE_INT_RGB); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
88 |
for (int i = 0; i < LOOP_COUNT; i++) { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
89 |
Graphics g = image.getGraphics(); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
90 |
if (lock) { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
91 |
synchronized (button.getTreeLock()) { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
92 |
button.paint(g); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
93 |
} |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
94 |
} else { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
95 |
button.paint(g); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
96 |
} |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
97 |
g.dispose(); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
98 |
} |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
99 |
} |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
100 |
|
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
101 |
private static void setLookAndFeel(final UIManager.LookAndFeelInfo laf) { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
102 |
try { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
103 |
UIManager.setLookAndFeel(laf.getClassName()); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
104 |
System.out.println("LookAndFeel: " + laf.getClassName()); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
105 |
} catch (ClassNotFoundException | InstantiationException | |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
106 |
UnsupportedLookAndFeelException | IllegalAccessException e) { |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
107 |
throw new RuntimeException(e); |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
108 |
} |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
109 |
} |
e89a68072d5b
8011541: [TEST_BUG] closed/javax/swing/plaf/metal/MetalUtils/bug6190373.java fails NPE since 7u25b03
serb
parents:
diff
changeset
|
110 |
} |