6461834: Minimize WindowsLookAndFeel classes included with Unix JDKs
authorpsadhukhan
Sat, 27 May 2017 12:55:33 +0530
changeset 47131 3c5b1a40f573
parent 47130 7dc75503383a
child 47132 0d03b6efffd3
6461834: Minimize WindowsLookAndFeel classes included with Unix JDKs Reviewed-by: ihse, aniyogi, prr
jdk/src/java.desktop/share/classes/module-info.java
jdk/src/java.desktop/windows/classes/module-info.java.extra
jdk/test/com/sun/java/swing/plaf/windows/Test6824600.java
jdk/test/javax/swing/JButton/4796987/bug4796987.java
jdk/test/javax/swing/JComboBox/4199622/bug4199622.java
jdk/test/javax/swing/JComboBox/8015300/Test8015300.java
jdk/test/javax/swing/JFileChooser/8046391/bug8046391.java
jdk/test/javax/swing/JInternalFrame/6725409/bug6725409.java
jdk/test/javax/swing/JSlider/6524424/bug6524424.java
jdk/test/javax/swing/JTree/8004298/bug8004298.java
jdk/test/javax/swing/border/Test4856008.java
jdk/test/javax/swing/border/Test6978482.java
--- a/jdk/src/java.desktop/share/classes/module-info.java	Thu May 25 09:15:55 2017 -0700
+++ b/jdk/src/java.desktop/share/classes/module-info.java	Sat May 27 12:55:33 2017 +0530
@@ -93,8 +93,6 @@
 
     opens javax.swing.plaf.basic to
         jdk.jconsole;
-    opens com.sun.java.swing.plaf.windows to
-        jdk.jconsole;
 
     uses java.awt.im.spi.InputMethodDescriptor;
     uses javax.accessibility.AccessibilityProvider;
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/jdk/src/java.desktop/windows/classes/module-info.java.extra	Sat May 27 12:55:33 2017 +0530
@@ -0,0 +1,26 @@
+/*
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+opens com.sun.java.swing.plaf.windows to jdk.jconsole;
--- a/jdk/test/com/sun/java/swing/plaf/windows/Test6824600.java	Thu May 25 09:15:55 2017 -0700
+++ b/jdk/test/com/sun/java/swing/plaf/windows/Test6824600.java	Sat May 27 12:55:33 2017 +0530
@@ -23,6 +23,7 @@
 
 /* @test
    @bug 6824600
+   @requires (os.family == "windows")
    @summary OOM occurs when setLookAndFeel() is executed in Windows L&F(XP style)
    @author Pavel Porvatov
    @modules java.desktop/com.sun.java.swing.plaf.windows
--- a/jdk/test/javax/swing/JButton/4796987/bug4796987.java	Thu May 25 09:15:55 2017 -0700
+++ b/jdk/test/javax/swing/JButton/4796987/bug4796987.java	Sat May 27 12:55:33 2017 +0530
@@ -24,6 +24,7 @@
 /*
  * @test
  * @bug 4796987
+ * @requires (os.family == "windows")
  * @summary XP Only: JButton.setBorderPainted() does not work with XP L&F
  * @author Alexander Scherbatiy
  * @library ../../regtesthelpers
--- a/jdk/test/javax/swing/JComboBox/4199622/bug4199622.java	Thu May 25 09:15:55 2017 -0700
+++ b/jdk/test/javax/swing/JComboBox/4199622/bug4199622.java	Sat May 27 12:55:33 2017 +0530
@@ -25,6 +25,7 @@
    @test
    @key headful
    @bug 4199622
+   @requires (os.family == "windows")
    @summary RFE: JComboBox shouldn't send ActionEvents for keyboard navigation
    @author Vladislav Karnaukhov
    @library ../../../../lib/testlibrary
--- a/jdk/test/javax/swing/JComboBox/8015300/Test8015300.java	Thu May 25 09:15:55 2017 -0700
+++ b/jdk/test/javax/swing/JComboBox/8015300/Test8015300.java	Sat May 27 12:55:33 2017 +0530
@@ -39,6 +39,7 @@
  * @test
  * @key headful
  * @bug 8015300
+ * @requires (os.family == "windows")
  * @summary Tests that editable combobox selects all text.
  * @author Sergey Malenkov
  * @library ../../../../lib/testlibrary/
--- a/jdk/test/javax/swing/JFileChooser/8046391/bug8046391.java	Thu May 25 09:15:55 2017 -0700
+++ b/jdk/test/javax/swing/JFileChooser/8046391/bug8046391.java	Sat May 27 12:55:33 2017 +0530
@@ -24,6 +24,7 @@
 /*
  * @test
  * @bug 8046391
+ * @requires (os.family == "windows")
  * @summary JFileChooser hangs if displayed in Windows L&F
  * @author Alexey Ivanov
  * @library ../../../../lib/testlibrary
--- a/jdk/test/javax/swing/JInternalFrame/6725409/bug6725409.java	Thu May 25 09:15:55 2017 -0700
+++ b/jdk/test/javax/swing/JInternalFrame/6725409/bug6725409.java	Sat May 27 12:55:33 2017 +0530
@@ -24,6 +24,7 @@
 /* @test
  * @key headful
  * @bug 6725409
+ * @requires (os.family == "windows")
  * @summary Checks that JInternalFrame's system menu
  *          can be localized during run-time
  * @author Mikhail Lapshin
--- a/jdk/test/javax/swing/JSlider/6524424/bug6524424.java	Thu May 25 09:15:55 2017 -0700
+++ b/jdk/test/javax/swing/JSlider/6524424/bug6524424.java	Sat May 27 12:55:33 2017 +0530
@@ -23,6 +23,7 @@
 
 /* @test
  * @bug 6524424
+ * @requires (os.family == "windows")
  * @summary JSlider Clicking In Tracks Behavior Inconsistent For Different Tick Spacings
  * @author Pavel Porvatov
  * @modules java.desktop/com.sun.java.swing.plaf.windows
--- a/jdk/test/javax/swing/JTree/8004298/bug8004298.java	Thu May 25 09:15:55 2017 -0700
+++ b/jdk/test/javax/swing/JTree/8004298/bug8004298.java	Sat May 27 12:55:33 2017 +0530
@@ -25,6 +25,7 @@
  * @test
  * @key headful
  * @bug 8004298
+ * @requires (os.family == "windows")
  * @summary NPE in WindowsTreeUI.ensureRowsAreVisible
  * @author Alexander Scherbatiy
  * @library ../../regtesthelpers
--- a/jdk/test/javax/swing/border/Test4856008.java	Thu May 25 09:15:55 2017 -0700
+++ b/jdk/test/javax/swing/border/Test4856008.java	Sat May 27 12:55:33 2017 +0530
@@ -24,6 +24,7 @@
 /*
  * @test
  * @bug 4856008 7025987
+ * @requires (os.family == "windows")
  * @summary Tests border insets
  * @author Sergey Malenkov
  * @modules java.desktop/com.sun.java.swing.plaf.motif
--- a/jdk/test/javax/swing/border/Test6978482.java	Thu May 25 09:15:55 2017 -0700
+++ b/jdk/test/javax/swing/border/Test6978482.java	Sat May 27 12:55:33 2017 +0530
@@ -24,6 +24,7 @@
 /*
  * @test
  * @bug 6978482 7025987
+ * @requires (os.family == "windows")
  * @summary Tests unchecked casts
  * @author Sergey Malenkov
  * @modules java.desktop/com.sun.java.swing.plaf.motif