changeset 48356:95f173494fe9

8189656: The Windows L&F should be moved out from the shared folder Reviewed-by: prr, psadhukhan, erikj
author serb
date Mon, 04 Dec 2017 16:14:29 -0800
parents f27aad5782da
children 128de6a38f8e
files src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/AnimationController.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/TMSchema.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsBorders.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsButtonListener.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsButtonUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsCheckBoxMenuItemUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsCheckBoxUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsClassicLookAndFeel.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsComboBoxUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsDesktopIconUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsDesktopManager.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsDesktopPaneUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsDesktopProperty.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsEditorPaneUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsFileChooserUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsGraphicsUtils.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsIconFactory.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsInternalFrameTitlePane.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsInternalFrameUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsLabelUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsLookAndFeel.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsMenuBarUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsMenuItemUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsMenuItemUIAccessor.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsMenuUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsOptionPaneUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsPasswordFieldUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsPopupMenuSeparatorUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsPopupMenuUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsPopupWindow.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsProgressBarUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsRadioButtonMenuItemUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsRadioButtonUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsRootPaneUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsScrollBarUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsScrollPaneUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsSeparatorUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsSliderUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsSpinnerUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsSplitPaneDivider.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsSplitPaneUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsTabbedPaneUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsTableHeaderUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsTextAreaUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsTextFieldUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsTextPaneUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsTextUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsToggleButtonUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsToolBarSeparatorUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsToolBarUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsTreeUI.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/XPStyle.java src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/Computer.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/DetailsView.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/Directory.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/Error.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/File.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/FloppyDrive.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/HardDrive.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/HomeFolder.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/Inform.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/JavaCup32.png src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/ListView.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/NewFolder.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/Question.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/TreeClosed.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/TreeLeaf.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/TreeOpen.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/UpFolder.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/Warn.gif src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/image-delayed.png src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/icons/image-failed.png src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/resources/windows.properties src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/resources/windows_de.properties src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/resources/windows_es.properties src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/resources/windows_fr.properties src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/resources/windows_it.properties src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/resources/windows_ja.properties src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/resources/windows_ko.properties src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/resources/windows_pt_BR.properties src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/resources/windows_sv.properties src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/resources/windows_zh_CN.properties src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/resources/windows_zh_TW.properties src/java.desktop/share/classes/module-info.java src/java.desktop/share/classes/sun/swing/plaf/windows/ClassicSortArrowIcon.java src/java.desktop/unix/classes/sun/awt/windows/ThemeReader.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/AnimationController.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/TMSchema.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsBorders.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsButtonListener.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsButtonUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsCheckBoxMenuItemUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsCheckBoxUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsClassicLookAndFeel.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsComboBoxUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsDesktopIconUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsDesktopManager.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsDesktopPaneUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsDesktopProperty.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsEditorPaneUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsFileChooserUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsGraphicsUtils.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsIconFactory.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsInternalFrameTitlePane.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsInternalFrameUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsLabelUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsLookAndFeel.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsMenuBarUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsMenuItemUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsMenuItemUIAccessor.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsMenuUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsOptionPaneUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsPasswordFieldUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsPopupMenuSeparatorUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsPopupMenuUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsPopupWindow.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsProgressBarUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsRadioButtonMenuItemUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsRadioButtonUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsRootPaneUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsScrollBarUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsScrollPaneUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsSeparatorUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsSliderUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsSpinnerUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsSplitPaneDivider.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsSplitPaneUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsTabbedPaneUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsTableHeaderUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsTextAreaUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsTextFieldUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsTextPaneUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsTextUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsToggleButtonUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsToolBarSeparatorUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsToolBarUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/WindowsTreeUI.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/XPStyle.java src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/Computer.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/DetailsView.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/Directory.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/Error.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/File.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/FloppyDrive.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/HardDrive.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/HomeFolder.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/Inform.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/JavaCup32.png src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/ListView.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/NewFolder.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/Question.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/TreeClosed.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/TreeLeaf.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/TreeOpen.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/UpFolder.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/Warn.gif src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/image-delayed.png src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/icons/image-failed.png src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/resources/windows.properties src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/resources/windows_de.properties src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/resources/windows_es.properties src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/resources/windows_fr.properties src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/resources/windows_it.properties src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/resources/windows_ja.properties src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/resources/windows_ko.properties src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/resources/windows_pt_BR.properties src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/resources/windows_sv.properties src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/resources/windows_zh_CN.properties src/java.desktop/windows/classes/com/sun/java/swing/plaf/windows/resources/windows_zh_TW.properties src/java.desktop/windows/classes/module-info.java.extra src/java.desktop/windows/classes/sun/swing/plaf/windows/ClassicSortArrowIcon.java test/jdk/com/sun/java/swing/plaf/windows/Test8173145.java test/jdk/javax/swing/JButton/4796987/bug4796987.java test/jdk/javax/swing/JComboBox/4199622/bug4199622.java test/jdk/javax/swing/JComboBox/8015300/Test8015300.java test/jdk/javax/swing/JFileChooser/4847375/bug4847375.java test/jdk/javax/swing/JFileChooser/8046391/bug8046391.java test/jdk/javax/swing/JInternalFrame/6725409/bug6725409.java test/jdk/javax/swing/JProgressBar/7141573/bug7141573.java test/jdk/javax/swing/JSlider/6524424/bug6524424.java test/jdk/javax/swing/JSlider/6579827/bug6579827.java test/jdk/javax/swing/JTree/8004298/bug8004298.java test/jdk/javax/swing/border/Test4856008.java test/jdk/javax/swing/border/Test6978482.java
diffstat 184 files changed, 15260 insertions(+), 15332 deletions(-) [+]
line wrap: on
line diff
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/AnimationController.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,436 +0,0 @@
-/*
- * Copyright (c) 2006, 2016, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import java.security.AccessController;
-import sun.security.action.GetBooleanAction;
-
-import java.util.*;
-import java.beans.PropertyChangeListener;
-import java.beans.PropertyChangeEvent;
-import java.awt.*;
-import java.awt.event.*;
-import javax.swing.*;
-
-
-import com.sun.java.swing.plaf.windows.TMSchema.State;
-import static com.sun.java.swing.plaf.windows.TMSchema.State.*;
-import com.sun.java.swing.plaf.windows.TMSchema.Part;
-import com.sun.java.swing.plaf.windows.TMSchema.Prop;
-import com.sun.java.swing.plaf.windows.XPStyle.Skin;
-
-import sun.awt.AppContext;
-
-/**
- * A class to help mimic Vista theme animations.  The only kind of
- * animation it handles for now is 'transition' animation (this seems
- * to be the only animation which Vista theme can do). This is when
- * one picture fadein over another one in some period of time.
- * According to
- * https://connect.microsoft.com/feedback/ViewFeedback.aspx?FeedbackID=86852&SiteID=4
- * The animations are all linear.
- *
- * This class has a number of responsibilities.
- * <ul>
- *   <li> It trigger rapaint for the UI components involved in the animation
- *   <li> It tracks the animation state for every UI component involved in the
- *        animation and paints {@code Skin} in new {@code State} over the
- *        {@code Skin} in last {@code State} using
- *        {@code AlphaComposite.SrcOver.derive(alpha)} where {code alpha}
- *        depends on the state of animation
- * </ul>
- *
- * @author Igor Kushnirskiy
- */
-class AnimationController implements ActionListener, PropertyChangeListener {
-
-    private static final boolean VISTA_ANIMATION_DISABLED =
-        AccessController.doPrivileged(new GetBooleanAction("swing.disablevistaanimation"));
-
-
-    private static final Object ANIMATION_CONTROLLER_KEY =
-        new StringBuilder("ANIMATION_CONTROLLER_KEY");
-
-    private final Map<JComponent, Map<Part, AnimationState>> animationStateMap =
-            new WeakHashMap<JComponent, Map<Part, AnimationState>>();
-
-    //this timer is used to cause repaint on animated components
-    //30 repaints per second should give smooth animation affect
-    private final javax.swing.Timer timer =
-        new javax.swing.Timer(1000/30, this);
-
-    private static synchronized AnimationController getAnimationController() {
-        AppContext appContext = AppContext.getAppContext();
-        Object obj = appContext.get(ANIMATION_CONTROLLER_KEY);
-        if (obj == null) {
-            obj = new AnimationController();
-            appContext.put(ANIMATION_CONTROLLER_KEY, obj);
-        }
-        return (AnimationController) obj;
-    }
-
-    private AnimationController() {
-        timer.setRepeats(true);
-        timer.setCoalesce(true);
-        //we need to dispose the controller on l&f change
-        UIManager.addPropertyChangeListener(this);
-    }
-
-    private static void triggerAnimation(JComponent c,
-                           Part part, State newState) {
-        if (c instanceof javax.swing.JTabbedPane
-            || part == Part.TP_BUTTON) {
-            //idk: we can not handle tabs animation because
-            //the same (component,part) is used to handle all the tabs
-            //and we can not track the states
-            //Vista theme might have transition duration for toolbar buttons
-            //but native application does not seem to animate them
-            return;
-        }
-        AnimationController controller =
-            AnimationController.getAnimationController();
-        State oldState = controller.getState(c, part);
-        if (oldState != newState) {
-            controller.putState(c, part, newState);
-            if (newState == State.DEFAULTED) {
-                // it seems for DEFAULTED button state Vista does animation from
-                // HOT
-                oldState = State.HOT;
-            }
-            if (oldState != null) {
-                long duration;
-                if (newState == State.DEFAULTED) {
-                    //Only button might have DEFAULTED state
-                    //idk: do not know how to get the value from Vista
-                    //one second seems plausible value
-                    duration = 1000;
-                } else {
-                    XPStyle xp = XPStyle.getXP();
-                    duration = (xp != null)
-                               ? xp.getThemeTransitionDuration(
-                                       c, part,
-                                       normalizeState(oldState),
-                                       normalizeState(newState),
-                                       Prop.TRANSITIONDURATIONS)
-                               : 1000;
-                }
-                controller.startAnimation(c, part, oldState, newState, duration);
-            }
-        }
-    }
-
-    // for scrollbar up, down, left and right button pictures are
-    // defined by states.  It seems that theme has duration defined
-    // only for up button states thus we doing this translation here.
-    private static State normalizeState(State state) {
-        State rv;
-        switch (state) {
-        case DOWNPRESSED:
-            /* falls through */
-        case LEFTPRESSED:
-            /* falls through */
-        case RIGHTPRESSED:
-            rv = UPPRESSED;
-            break;
-
-        case DOWNDISABLED:
-            /* falls through */
-        case LEFTDISABLED:
-            /* falls through */
-        case RIGHTDISABLED:
-            rv = UPDISABLED;
-            break;
-
-        case DOWNHOT:
-            /* falls through */
-        case LEFTHOT:
-            /* falls through */
-        case RIGHTHOT:
-            rv = UPHOT;
-            break;
-
-        case DOWNNORMAL:
-            /* falls through */
-        case LEFTNORMAL:
-            /* falls through */
-        case RIGHTNORMAL:
-            rv = UPNORMAL;
-            break;
-
-        default :
-            rv = state;
-            break;
-        }
-        return rv;
-    }
-
-    private synchronized State getState(JComponent component, Part part) {
-        State rv = null;
-        Object tmpObject =
-            component.getClientProperty(PartUIClientPropertyKey.getKey(part));
-        if (tmpObject instanceof State) {
-            rv = (State) tmpObject;
-        }
-        return rv;
-    }
-
-    private synchronized void putState(JComponent component, Part part,
-                                       State state) {
-        component.putClientProperty(PartUIClientPropertyKey.getKey(part),
-                                    state);
-    }
-
-    private synchronized void startAnimation(JComponent component,
-                                     Part part,
-                                     State startState,
-                                     State endState,
-                                     long millis) {
-        boolean isForwardAndReverse = false;
-        if (endState == State.DEFAULTED) {
-            isForwardAndReverse = true;
-        }
-        Map<Part, AnimationState> map = animationStateMap.get(component);
-        if (millis <= 0) {
-            if (map != null) {
-                map.remove(part);
-                if (map.size() == 0) {
-                    animationStateMap.remove(component);
-                }
-            }
-            return;
-        }
-        if (map == null) {
-            map = new EnumMap<Part, AnimationState>(Part.class);
-            animationStateMap.put(component, map);
-        }
-        map.put(part,
-                new AnimationState(startState, millis, isForwardAndReverse));
-        if (! timer.isRunning()) {
-            timer.start();
-        }
-    }
-
-    static void paintSkin(JComponent component, Skin skin,
-                      Graphics g, int dx, int dy, int dw, int dh, State state) {
-        if (VISTA_ANIMATION_DISABLED) {
-            skin.paintSkinRaw(g, dx, dy, dw, dh, state);
-            return;
-        }
-        triggerAnimation(component, skin.part, state);
-        AnimationController controller = getAnimationController();
-        synchronized (controller) {
-            AnimationState animationState = null;
-            Map<Part, AnimationState> map =
-                controller.animationStateMap.get(component);
-            if (map != null) {
-                animationState = map.get(skin.part);
-            }
-            if (animationState != null) {
-                animationState.paintSkin(skin, g, dx, dy, dw, dh, state);
-            } else {
-                skin.paintSkinRaw(g, dx, dy, dw, dh, state);
-            }
-        }
-    }
-
-    public synchronized void propertyChange(PropertyChangeEvent e) {
-        if ("lookAndFeel" == e.getPropertyName()
-            && ! (e.getNewValue() instanceof WindowsLookAndFeel) ) {
-            dispose();
-        }
-    }
-
-    public synchronized void actionPerformed(ActionEvent e) {
-        java.util.List<JComponent> componentsToRemove = null;
-        java.util.List<Part> partsToRemove = null;
-        for (JComponent component : animationStateMap.keySet()) {
-            component.repaint();
-            if (partsToRemove != null) {
-                partsToRemove.clear();
-            }
-            Map<Part, AnimationState> map = animationStateMap.get(component);
-            if (! component.isShowing()
-                  || map == null
-                  || map.size() == 0) {
-                if (componentsToRemove == null) {
-                    componentsToRemove = new ArrayList<JComponent>();
-                }
-                componentsToRemove.add(component);
-                continue;
-            }
-            for (Part part : map.keySet()) {
-                if (map.get(part).isDone()) {
-                    if (partsToRemove == null) {
-                        partsToRemove = new ArrayList<Part>();
-                    }
-                    partsToRemove.add(part);
-                }
-            }
-            if (partsToRemove != null) {
-                if (partsToRemove.size() == map.size()) {
-                    //animation is done for the component
-                    if (componentsToRemove == null) {
-                        componentsToRemove = new ArrayList<JComponent>();
-                    }
-                    componentsToRemove.add(component);
-                } else {
-                    for (Part part : partsToRemove) {
-                        map.remove(part);
-                    }
-                }
-            }
-        }
-        if (componentsToRemove != null) {
-            for (JComponent component : componentsToRemove) {
-                animationStateMap.remove(component);
-            }
-        }
-        if (animationStateMap.size() == 0) {
-            timer.stop();
-        }
-    }
-
-    private synchronized void dispose() {
-        timer.stop();
-        UIManager.removePropertyChangeListener(this);
-        synchronized (AnimationController.class) {
-            AppContext.getAppContext()
-                .put(ANIMATION_CONTROLLER_KEY, null);
-        }
-    }
-
-    private static class AnimationState {
-        private final State startState;
-
-        //animation duration in nanoseconds
-        private final long duration;
-
-        //animatin start time in nanoseconds
-        private long startTime;
-
-        //direction the alpha value is changing
-        //forward  - from 0 to 1
-        //!forward - from 1 to 0
-        private boolean isForward = true;
-
-        //if isForwardAndReverse the animation continually goes
-        //forward and reverse. alpha value is changing from 0 to 1 then
-        //from 1 to 0 and so forth
-        private boolean isForwardAndReverse;
-
-        private float progress;
-
-        AnimationState(final State startState,
-                       final long milliseconds,
-                       boolean isForwardAndReverse) {
-            assert startState != null && milliseconds > 0;
-            assert SwingUtilities.isEventDispatchThread();
-
-            this.startState = startState;
-            this.duration = milliseconds * 1000000;
-            this.startTime = System.nanoTime();
-            this.isForwardAndReverse = isForwardAndReverse;
-            progress = 0f;
-        }
-        private void updateProgress() {
-            assert SwingUtilities.isEventDispatchThread();
-
-            if (isDone()) {
-                return;
-            }
-            long currentTime = System.nanoTime();
-
-            progress = ((float) (currentTime - startTime))
-                / duration;
-            progress = Math.max(progress, 0); //in case time was reset
-            if (progress >= 1) {
-                progress = 1;
-                if (isForwardAndReverse) {
-                    startTime = currentTime;
-                    progress = 0;
-                    isForward = ! isForward;
-                }
-            }
-        }
-        void paintSkin(Skin skin, Graphics _g,
-                       int dx, int dy, int dw, int dh, State state) {
-            assert SwingUtilities.isEventDispatchThread();
-
-            updateProgress();
-            if (! isDone()) {
-                Graphics2D g = (Graphics2D) _g.create();
-                if (skin.haveToSwitchStates()) {
-                    skin.paintSkinRaw(g, dx, dy, dw, dh, state);
-                    g.setComposite(AlphaComposite.SrcOver.derive(1 - progress));
-                    skin.paintSkinRaw(g, dx, dy, dw, dh, startState);
-                } else {
-                    skin.paintSkinRaw(g, dx, dy, dw, dh, startState);
-                    float alpha;
-                    if (isForward) {
-                        alpha = progress;
-                    } else {
-                        alpha = 1 - progress;
-                    }
-                    g.setComposite(AlphaComposite.SrcOver.derive(alpha));
-                    skin.paintSkinRaw(g, dx, dy, dw, dh, state);
-                }
-                g.dispose();
-            } else {
-                skin.paintSkinRaw(_g, dx, dy, dw, dh, state);
-                skin.switchStates(false);
-            }
-        }
-        boolean isDone() {
-            assert SwingUtilities.isEventDispatchThread();
-
-            return  progress >= 1;
-        }
-    }
-
-    private static class PartUIClientPropertyKey
-          implements UIClientPropertyKey {
-
-        private static final Map<Part, PartUIClientPropertyKey> map =
-            new EnumMap<Part, PartUIClientPropertyKey>(Part.class);
-
-        static synchronized PartUIClientPropertyKey getKey(Part part) {
-            PartUIClientPropertyKey rv = map.get(part);
-            if (rv == null) {
-                rv = new PartUIClientPropertyKey(part);
-                map.put(part, rv);
-            }
-            return rv;
-        }
-
-        private final Part part;
-        private PartUIClientPropertyKey(Part part) {
-            this.part  = part;
-        }
-        public String toString() {
-            return part.toString();
-        }
-    }
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/TMSchema.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,577 +0,0 @@
-/*
- * Copyright (c) 2005, 2014, 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.
- */
-
-/*
- * <p>These classes are designed to be used while the
- * corresponding <code>LookAndFeel</code> class has been installed
- * (<code>UIManager.setLookAndFeel(new <i>XXX</i>LookAndFeel())</code>).
- * Using them while a different <code>LookAndFeel</code> is installed
- * may produce unexpected results, including exceptions.
- * Additionally, changing the <code>LookAndFeel</code>
- * maintained by the <code>UIManager</code> without updating the
- * corresponding <code>ComponentUI</code> of any
- * <code>JComponent</code>s may also produce unexpected results,
- * such as the wrong colors showing up, and is generally not
- * encouraged.
- *
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import java.awt.*;
-import java.util.*;
-
-import javax.swing.*;
-
-import sun.awt.windows.ThemeReader;
-
-/**
- * Implements Windows Parts and their States and Properties for the Windows Look and Feel.
- *
- * See http://msdn.microsoft.com/library/default.asp?url=/library/en-us/shellcc/platform/commctls/userex/topics/partsandstates.asp
- * See tmschema.h (or vssym32.h & vsstyle.h for MS Vista)
- *
- * @author Leif Samuelsson
- */
-class TMSchema {
-
-    /**
-     * An enumeration of the various Windows controls (also known as
-     * components, or top-level parts)
-     */
-    public static enum Control {
-        BUTTON,
-        COMBOBOX,
-        EDIT,
-        HEADER,
-        LISTBOX,
-        LISTVIEW,
-        MENU,
-        PROGRESS,
-        REBAR,
-        SCROLLBAR,
-        SPIN,
-        TAB,
-        TOOLBAR,
-        TRACKBAR,
-        TREEVIEW,
-        WINDOW
-    }
-
-
-    /**
-     * An enumeration of the Windows compoent parts
-     */
-    public static enum Part {
-        MENU (Control.MENU, 0), // Special case, not in native
-        MP_BARBACKGROUND   (Control.MENU, 7),
-        MP_BARITEM         (Control.MENU, 8),
-        MP_POPUPBACKGROUND (Control.MENU, 9),
-        MP_POPUPBORDERS    (Control.MENU, 10),
-        MP_POPUPCHECK      (Control.MENU, 11),
-        MP_POPUPCHECKBACKGROUND (Control.MENU, 12),
-        MP_POPUPGUTTER     (Control.MENU, 13),
-        MP_POPUPITEM       (Control.MENU, 14),
-        MP_POPUPSEPARATOR  (Control.MENU, 15),
-        MP_POPUPSUBMENU    (Control.MENU, 16),
-
-        BP_PUSHBUTTON (Control.BUTTON, 1),
-        BP_RADIOBUTTON(Control.BUTTON, 2),
-        BP_CHECKBOX   (Control.BUTTON, 3),
-        BP_GROUPBOX   (Control.BUTTON, 4),
-
-        CP_COMBOBOX      (Control.COMBOBOX, 0),
-        CP_DROPDOWNBUTTON(Control.COMBOBOX, 1),
-        CP_BACKGROUND    (Control.COMBOBOX, 2),
-        CP_TRANSPARENTBACKGROUND (Control.COMBOBOX, 3),
-        CP_BORDER                (Control.COMBOBOX, 4),
-        CP_READONLY              (Control.COMBOBOX, 5),
-        CP_DROPDOWNBUTTONRIGHT   (Control.COMBOBOX, 6),
-        CP_DROPDOWNBUTTONLEFT    (Control.COMBOBOX, 7),
-        CP_CUEBANNER             (Control.COMBOBOX, 8),
-
-
-        EP_EDIT    (Control.EDIT, 0),
-        EP_EDITTEXT(Control.EDIT, 1),
-
-        HP_HEADERITEM(Control.HEADER,      1),
-        HP_HEADERSORTARROW(Control.HEADER, 4),
-
-        LBP_LISTBOX(Control.LISTBOX, 0),
-
-        LBCP_BORDER_HSCROLL  (Control.LISTBOX, 1),
-        LBCP_BORDER_HVSCROLL (Control.LISTBOX, 2),
-        LBCP_BORDER_NOSCROLL (Control.LISTBOX, 3),
-        LBCP_BORDER_VSCROLL  (Control.LISTBOX, 4),
-        LBCP_ITEM            (Control.LISTBOX, 5),
-
-        LVP_LISTVIEW(Control.LISTVIEW, 0),
-
-        PP_PROGRESS (Control.PROGRESS, 0),
-        PP_BAR      (Control.PROGRESS, 1),
-        PP_BARVERT  (Control.PROGRESS, 2),
-        PP_CHUNK    (Control.PROGRESS, 3),
-        PP_CHUNKVERT(Control.PROGRESS, 4),
-
-        RP_GRIPPER    (Control.REBAR, 1),
-        RP_GRIPPERVERT(Control.REBAR, 2),
-
-        SBP_SCROLLBAR     (Control.SCROLLBAR,  0),
-        SBP_ARROWBTN      (Control.SCROLLBAR,  1),
-        SBP_THUMBBTNHORZ  (Control.SCROLLBAR,  2),
-        SBP_THUMBBTNVERT  (Control.SCROLLBAR,  3),
-        SBP_LOWERTRACKHORZ(Control.SCROLLBAR,  4),
-        SBP_UPPERTRACKHORZ(Control.SCROLLBAR,  5),
-        SBP_LOWERTRACKVERT(Control.SCROLLBAR,  6),
-        SBP_UPPERTRACKVERT(Control.SCROLLBAR,  7),
-        SBP_GRIPPERHORZ   (Control.SCROLLBAR,  8),
-        SBP_GRIPPERVERT   (Control.SCROLLBAR,  9),
-        SBP_SIZEBOX       (Control.SCROLLBAR, 10),
-
-        SPNP_UP  (Control.SPIN, 1),
-        SPNP_DOWN(Control.SPIN, 2),
-
-        TABP_TABITEM         (Control.TAB, 1),
-        TABP_TABITEMLEFTEDGE (Control.TAB, 2),
-        TABP_TABITEMRIGHTEDGE(Control.TAB, 3),
-        TABP_PANE            (Control.TAB, 9),
-
-        TP_TOOLBAR        (Control.TOOLBAR, 0),
-        TP_BUTTON         (Control.TOOLBAR, 1),
-        TP_SEPARATOR      (Control.TOOLBAR, 5),
-        TP_SEPARATORVERT  (Control.TOOLBAR, 6),
-
-        TKP_TRACK      (Control.TRACKBAR,  1),
-        TKP_TRACKVERT  (Control.TRACKBAR,  2),
-        TKP_THUMB      (Control.TRACKBAR,  3),
-        TKP_THUMBBOTTOM(Control.TRACKBAR,  4),
-        TKP_THUMBTOP   (Control.TRACKBAR,  5),
-        TKP_THUMBVERT  (Control.TRACKBAR,  6),
-        TKP_THUMBLEFT  (Control.TRACKBAR,  7),
-        TKP_THUMBRIGHT (Control.TRACKBAR,  8),
-        TKP_TICS       (Control.TRACKBAR,  9),
-        TKP_TICSVERT   (Control.TRACKBAR, 10),
-
-        TVP_TREEVIEW(Control.TREEVIEW, 0),
-        TVP_GLYPH   (Control.TREEVIEW, 2),
-
-        WP_WINDOW          (Control.WINDOW,  0),
-        WP_CAPTION         (Control.WINDOW,  1),
-        WP_MINCAPTION      (Control.WINDOW,  3),
-        WP_MAXCAPTION      (Control.WINDOW,  5),
-        WP_FRAMELEFT       (Control.WINDOW,  7),
-        WP_FRAMERIGHT      (Control.WINDOW,  8),
-        WP_FRAMEBOTTOM     (Control.WINDOW,  9),
-        WP_SYSBUTTON       (Control.WINDOW, 13),
-        WP_MDISYSBUTTON    (Control.WINDOW, 14),
-        WP_MINBUTTON       (Control.WINDOW, 15),
-        WP_MDIMINBUTTON    (Control.WINDOW, 16),
-        WP_MAXBUTTON       (Control.WINDOW, 17),
-        WP_CLOSEBUTTON     (Control.WINDOW, 18),
-        WP_MDICLOSEBUTTON  (Control.WINDOW, 20),
-        WP_RESTOREBUTTON   (Control.WINDOW, 21),
-        WP_MDIRESTOREBUTTON(Control.WINDOW, 22);
-
-        private final Control control;
-        private final int value;
-
-        private Part(Control control, int value) {
-            this.control = control;
-            this.value = value;
-        }
-
-        public int getValue() {
-            return value;
-        }
-
-        public String getControlName(Component component) {
-            String str = "";
-            if (component instanceof JComponent) {
-                JComponent c = (JComponent)component;
-                String subAppName = (String)c.getClientProperty("XPStyle.subAppName");
-                if (subAppName != null) {
-                    str = subAppName + "::";
-                }
-            }
-            return str + control.toString();
-        }
-
-        public String toString() {
-            return control.toString()+"."+name();
-        }
-    }
-
-
-    /**
-     * An enumeration of the possible component states
-     */
-    public static enum State {
-        ACTIVE,
-        ASSIST,
-        BITMAP,
-        CHECKED,
-        CHECKEDDISABLED,
-        CHECKEDHOT,
-        CHECKEDNORMAL,
-        CHECKEDPRESSED,
-        CHECKMARKNORMAL,
-        CHECKMARKDISABLED,
-        BULLETNORMAL,
-        BULLETDISABLED,
-        CLOSED,
-        DEFAULTED,
-        DISABLED,
-        DISABLEDHOT,
-        DISABLEDPUSHED,
-        DOWNDISABLED,
-        DOWNHOT,
-        DOWNNORMAL,
-        DOWNPRESSED,
-        FOCUSED,
-        HOT,
-        HOTCHECKED,
-        ICONHOT,
-        ICONNORMAL,
-        ICONPRESSED,
-        ICONSORTEDHOT,
-        ICONSORTEDNORMAL,
-        ICONSORTEDPRESSED,
-        INACTIVE,
-        INACTIVENORMAL,         // See note 1
-        INACTIVEHOT,            // See note 1
-        INACTIVEPUSHED,         // See note 1
-        INACTIVEDISABLED,       // See note 1
-        LEFTDISABLED,
-        LEFTHOT,
-        LEFTNORMAL,
-        LEFTPRESSED,
-        MIXEDDISABLED,
-        MIXEDHOT,
-        MIXEDNORMAL,
-        MIXEDPRESSED,
-        NORMAL,
-        PRESSED,
-        OPENED,
-        PUSHED,
-        READONLY,
-        RIGHTDISABLED,
-        RIGHTHOT,
-        RIGHTNORMAL,
-        RIGHTPRESSED,
-        SELECTED,
-        UNCHECKEDDISABLED,
-        UNCHECKEDHOT,
-        UNCHECKEDNORMAL,
-        UNCHECKEDPRESSED,
-        UPDISABLED,
-        UPHOT,
-        UPNORMAL,
-        UPPRESSED,
-        HOVER,
-        UPHOVER,
-        DOWNHOVER,
-        LEFTHOVER,
-        RIGHTHOVER,
-        SORTEDDOWN,
-        SORTEDHOT,
-        SORTEDNORMAL,
-        SORTEDPRESSED,
-        SORTEDUP;
-
-
-        /**
-         * A map of allowed states for each Part
-         */
-        private static EnumMap<Part, State[]> stateMap;
-
-        private static synchronized void initStates() {
-            stateMap = new EnumMap<Part, State[]>(Part.class);
-
-            stateMap.put(Part.EP_EDITTEXT,
-                       new State[] {
-                        NORMAL, HOT, SELECTED, DISABLED, FOCUSED, READONLY, ASSIST
-            });
-
-            stateMap.put(Part.BP_PUSHBUTTON,
-                       new State[] { NORMAL, HOT, PRESSED, DISABLED, DEFAULTED });
-
-            stateMap.put(Part.BP_RADIOBUTTON,
-                       new State[] {
-                        UNCHECKEDNORMAL, UNCHECKEDHOT, UNCHECKEDPRESSED, UNCHECKEDDISABLED,
-                        CHECKEDNORMAL,   CHECKEDHOT,   CHECKEDPRESSED,   CHECKEDDISABLED
-            });
-
-            stateMap.put(Part.BP_CHECKBOX,
-                       new State[] {
-                        UNCHECKEDNORMAL, UNCHECKEDHOT, UNCHECKEDPRESSED, UNCHECKEDDISABLED,
-                        CHECKEDNORMAL,   CHECKEDHOT,   CHECKEDPRESSED,   CHECKEDDISABLED,
-                        MIXEDNORMAL,     MIXEDHOT,     MIXEDPRESSED,     MIXEDDISABLED
-            });
-
-            State[] comboBoxStates = new State[] { NORMAL, HOT, PRESSED, DISABLED };
-            stateMap.put(Part.CP_COMBOBOX, comboBoxStates);
-            stateMap.put(Part.CP_DROPDOWNBUTTON, comboBoxStates);
-            stateMap.put(Part.CP_BACKGROUND, comboBoxStates);
-            stateMap.put(Part.CP_TRANSPARENTBACKGROUND, comboBoxStates);
-            stateMap.put(Part.CP_BORDER, comboBoxStates);
-            stateMap.put(Part.CP_READONLY, comboBoxStates);
-            stateMap.put(Part.CP_DROPDOWNBUTTONRIGHT, comboBoxStates);
-            stateMap.put(Part.CP_DROPDOWNBUTTONLEFT, comboBoxStates);
-            stateMap.put(Part.CP_CUEBANNER, comboBoxStates);
-
-            stateMap.put(Part.HP_HEADERITEM, new State[] { NORMAL, HOT, PRESSED,
-                          SORTEDNORMAL, SORTEDHOT, SORTEDPRESSED,
-                          ICONNORMAL, ICONHOT, ICONPRESSED,
-                          ICONSORTEDNORMAL, ICONSORTEDHOT, ICONSORTEDPRESSED });
-
-            stateMap.put(Part.HP_HEADERSORTARROW,
-                         new State[] {SORTEDDOWN, SORTEDUP});
-
-            State[] listBoxStates = new State[] { NORMAL, PRESSED, HOT, DISABLED};
-            stateMap.put(Part.LBCP_BORDER_HSCROLL, listBoxStates);
-            stateMap.put(Part.LBCP_BORDER_HVSCROLL, listBoxStates);
-            stateMap.put(Part.LBCP_BORDER_NOSCROLL, listBoxStates);
-            stateMap.put(Part.LBCP_BORDER_VSCROLL, listBoxStates);
-
-            State[] scrollBarStates = new State[] { NORMAL, HOT, PRESSED, DISABLED, HOVER };
-            stateMap.put(Part.SBP_SCROLLBAR,    scrollBarStates);
-            stateMap.put(Part.SBP_THUMBBTNVERT, scrollBarStates);
-            stateMap.put(Part.SBP_THUMBBTNHORZ, scrollBarStates);
-            stateMap.put(Part.SBP_GRIPPERVERT,  scrollBarStates);
-            stateMap.put(Part.SBP_GRIPPERHORZ,  scrollBarStates);
-
-            stateMap.put(Part.SBP_ARROWBTN,
-                       new State[] {
-                UPNORMAL,    UPHOT,     UPPRESSED,    UPDISABLED,
-                DOWNNORMAL,  DOWNHOT,   DOWNPRESSED,  DOWNDISABLED,
-                LEFTNORMAL,  LEFTHOT,   LEFTPRESSED,  LEFTDISABLED,
-                RIGHTNORMAL, RIGHTHOT,  RIGHTPRESSED, RIGHTDISABLED,
-                UPHOVER,     DOWNHOVER, LEFTHOVER,    RIGHTHOVER
-            });
-
-
-            State[] spinnerStates = new State[] { NORMAL, HOT, PRESSED, DISABLED };
-            stateMap.put(Part.SPNP_UP,   spinnerStates);
-            stateMap.put(Part.SPNP_DOWN, spinnerStates);
-
-            stateMap.put(Part.TVP_GLYPH, new State[] { CLOSED, OPENED });
-
-            State[] frameButtonStates = new State[] {
-                        NORMAL,         HOT,         PUSHED,         DISABLED,  // See note 1
-                        INACTIVENORMAL, INACTIVEHOT, INACTIVEPUSHED, INACTIVEDISABLED,
-            };
-            // Note 1: The INACTIVE frame button states apply when the frame
-            //         is inactive. They are not defined in tmschema.h
-
-            // Fix for 6316538: Vista has five frame button states
-            if (ThemeReader.getInt(Control.WINDOW.toString(),
-                                   Part.WP_CLOSEBUTTON.getValue(), 1,
-                                   Prop.IMAGECOUNT.getValue()) == 10) {
-                frameButtonStates = new State[] {
-                        NORMAL,         HOT,         PUSHED,         DISABLED,         null,
-                        INACTIVENORMAL, INACTIVEHOT, INACTIVEPUSHED, INACTIVEDISABLED, null
-                };
-            }
-
-            stateMap.put(Part.WP_MINBUTTON,     frameButtonStates);
-            stateMap.put(Part.WP_MAXBUTTON,     frameButtonStates);
-            stateMap.put(Part.WP_RESTOREBUTTON, frameButtonStates);
-            stateMap.put(Part.WP_CLOSEBUTTON,   frameButtonStates);
-
-            // States for Slider (trackbar)
-            stateMap.put(Part.TKP_TRACK,     new State[] { NORMAL });
-            stateMap.put(Part.TKP_TRACKVERT, new State[] { NORMAL });
-
-            State[] sliderThumbStates =
-                new State[] { NORMAL, HOT, PRESSED, FOCUSED, DISABLED };
-            stateMap.put(Part.TKP_THUMB,       sliderThumbStates);
-            stateMap.put(Part.TKP_THUMBBOTTOM, sliderThumbStates);
-            stateMap.put(Part.TKP_THUMBTOP,    sliderThumbStates);
-            stateMap.put(Part.TKP_THUMBVERT,   sliderThumbStates);
-            stateMap.put(Part.TKP_THUMBRIGHT,  sliderThumbStates);
-
-            // States for Tabs
-            State[] tabStates = new State[] { NORMAL, HOT, SELECTED, DISABLED, FOCUSED };
-            stateMap.put(Part.TABP_TABITEM,          tabStates);
-            stateMap.put(Part.TABP_TABITEMLEFTEDGE,  tabStates);
-            stateMap.put(Part.TABP_TABITEMRIGHTEDGE, tabStates);
-
-
-            stateMap.put(Part.TP_BUTTON,
-                       new State[] {
-                        NORMAL, HOT, PRESSED, DISABLED, CHECKED, HOTCHECKED
-            });
-
-            State[] frameStates = new State[] { ACTIVE, INACTIVE };
-            stateMap.put(Part.WP_WINDOW,      frameStates);
-            stateMap.put(Part.WP_FRAMELEFT,   frameStates);
-            stateMap.put(Part.WP_FRAMERIGHT,  frameStates);
-            stateMap.put(Part.WP_FRAMEBOTTOM, frameStates);
-
-            State[] captionStates = new State[] { ACTIVE, INACTIVE, DISABLED };
-            stateMap.put(Part.WP_CAPTION,    captionStates);
-            stateMap.put(Part.WP_MINCAPTION, captionStates);
-            stateMap.put(Part.WP_MAXCAPTION, captionStates);
-
-            stateMap.put(Part.MP_BARBACKGROUND,
-                         new State[] { ACTIVE, INACTIVE });
-            stateMap.put(Part.MP_BARITEM,
-                         new State[] { NORMAL, HOT, PUSHED,
-                                       DISABLED, DISABLEDHOT, DISABLEDPUSHED });
-            stateMap.put(Part.MP_POPUPCHECK,
-                         new State[] { CHECKMARKNORMAL, CHECKMARKDISABLED,
-                                       BULLETNORMAL, BULLETDISABLED });
-            stateMap.put(Part.MP_POPUPCHECKBACKGROUND,
-                         new State[] { DISABLEDPUSHED, NORMAL, BITMAP });
-            stateMap.put(Part.MP_POPUPITEM,
-                         new State[] { NORMAL, HOT, DISABLED, DISABLEDHOT });
-            stateMap.put(Part.MP_POPUPSUBMENU,
-                         new State[] { NORMAL, DISABLED });
-
-        }
-
-
-        public static synchronized int getValue(Part part, State state) {
-            if (stateMap == null) {
-                initStates();
-            }
-
-            Enum<?>[] states = stateMap.get(part);
-            if (states != null) {
-                for (int i = 0; i < states.length; i++) {
-                    if (state == states[i]) {
-                        return i + 1;
-                    }
-                }
-            }
-
-            if (state == null || state == State.NORMAL) {
-                return 1;
-            }
-
-            return 0;
-        }
-
-    }
-
-
-    /**
-     * An enumeration of the possible component attributes and the
-     * corresponding value type
-     */
-    public static enum Prop {
-        COLOR(Color.class,                204),
-        SIZE(Dimension.class,             207),
-
-        FLATMENUS(Boolean.class,         1001),
-
-        BORDERONLY(Boolean.class,        2203), // only draw the border area of the image
-
-        IMAGECOUNT(Integer.class,        2401), // the number of state images in an imagefile
-        BORDERSIZE(Integer.class,        2403), // the size of the border line for bgtype=BorderFill
-
-        PROGRESSCHUNKSIZE(Integer.class, 2411), // size of progress control chunks
-        PROGRESSSPACESIZE(Integer.class, 2412), // size of progress control spaces
-
-        TEXTSHADOWOFFSET(Point.class,    3402), // where char shadows are drawn, relative to orig. chars
-
-        NORMALSIZE(Dimension.class,      3409), // size of dest rect that exactly source
-
-
-        SIZINGMARGINS ( Insets.class,    3601), // margins used for 9-grid sizing
-        CONTENTMARGINS(Insets.class,     3602), // margins that define where content can be placed
-        CAPTIONMARGINS(Insets.class,     3603), // margins that define where caption text can be placed
-
-        BORDERCOLOR(Color.class,         3801), // color of borders for BorderFill
-        FILLCOLOR  (  Color.class,       3802), // color of bg fill
-        TEXTCOLOR  (  Color.class,       3803), // color text is drawn in
-
-        TEXTSHADOWCOLOR(Color.class,     3818), // color of text shadow
-
-        BGTYPE(Integer.class,            4001), // basic drawing type for each part
-
-        TEXTSHADOWTYPE(Integer.class,    4010), // type of shadow to draw with text
-
-        TRANSITIONDURATIONS(Integer.class, 6000);
-
-        private final Class<?> type;
-        private final int value;
-
-        private Prop(Class<?> type, int value) {
-            this.type     = type;
-            this.value    = value;
-        }
-
-        public int getValue() {
-            return value;
-        }
-
-        public String toString() {
-            return name()+"["+type.getName()+"] = "+value;
-        }
-    }
-
-
-    /**
-     * An enumeration of attribute values for some Props
-     */
-    public static enum TypeEnum {
-        BT_IMAGEFILE (Prop.BGTYPE, "imagefile",  0),
-        BT_BORDERFILL(Prop.BGTYPE, "borderfill", 1),
-
-        TST_NONE(Prop.TEXTSHADOWTYPE, "none", 0),
-        TST_SINGLE(Prop.TEXTSHADOWTYPE, "single", 1),
-        TST_CONTINUOUS(Prop.TEXTSHADOWTYPE, "continuous", 2);
-
-
-        private TypeEnum(Prop prop, String enumName, int value) {
-            this.prop = prop;
-            this.enumName = enumName;
-            this.value = value;
-        }
-
-        private final Prop prop;
-        private final String enumName;
-        private final int value;
-
-        public String toString() {
-            return prop+"="+enumName+"="+value;
-        }
-
-        String getName() {
-            return enumName;
-        }
-
-
-        static TypeEnum getTypeEnum(Prop prop, int enumval) {
-            for (TypeEnum e : TypeEnum.values()) {
-                if (e.prop == prop && e.value == enumval) {
-                    return e;
-                }
-            }
-            return null;
-        }
-    }
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsBorders.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,341 +0,0 @@
-/*
- * Copyright (c) 1998, 2014, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import javax.swing.*;
-import javax.swing.border.*;
-import javax.swing.plaf.*;
-import javax.swing.plaf.basic.*;
-
-import java.awt.Component;
-import java.awt.Insets;
-import java.awt.Color;
-import java.awt.Graphics;
-
-import static com.sun.java.swing.plaf.windows.TMSchema.*;
-import static com.sun.java.swing.plaf.windows.XPStyle.Skin;
-
-/**
- * Factory object that can vend Borders appropriate for the Windows 95 {@literal L & F}.
- * @author Rich Schiavi
- */
-
-public class WindowsBorders {
-
-    /**
-     * Returns a  border instance for a Windows Progress Bar
-     * @since 1.4
-     */
-    public static Border getProgressBarBorder() {
-        UIDefaults table = UIManager.getLookAndFeelDefaults();
-        Border progressBarBorder = new BorderUIResource.CompoundBorderUIResource(
-                                         new WindowsBorders.ProgressBarBorder(
-                                              table.getColor("ProgressBar.shadow"),
-                                              table.getColor("ProgressBar.highlight")),
-                                              new EmptyBorder(1,1,1,1)
-                                        );
-        return progressBarBorder;
-    }
-
-    /**
-     * Returns a border instance for a Windows ToolBar
-     *
-     * @return a border used for the toolbar
-     * @since 1.4
-     */
-    public static Border getToolBarBorder() {
-        UIDefaults table = UIManager.getLookAndFeelDefaults();
-        Border toolBarBorder = new WindowsBorders.ToolBarBorder(
-                                        table.getColor("ToolBar.shadow"),
-                                        table.getColor("ToolBar.highlight"));
-        return toolBarBorder;
-    }
-
-    /**
-     * Returns an new instance of a border used to indicate which cell item
-     * has focus.
-     *
-     * @return a border to indicate which cell item has focus
-     * @since 1.4
-     */
-    public static Border getFocusCellHighlightBorder() {
-        return new ComplementDashedBorder();
-    }
-
-    public static Border getTableHeaderBorder() {
-        UIDefaults table = UIManager.getLookAndFeelDefaults();
-        Border tableHeaderBorder = new BorderUIResource.CompoundBorderUIResource(
-                           new BasicBorders.ButtonBorder(
-                                           table.getColor("Table.shadow"),
-                                           table.getColor("Table.darkShadow"),
-                                           table.getColor("Table.light"),
-                                           table.getColor("Table.highlight")),
-                                     new BasicBorders.MarginBorder());
-        return tableHeaderBorder;
-    }
-
-    public static Border getInternalFrameBorder() {
-        UIDefaults table = UIManager.getLookAndFeelDefaults();
-        Border internalFrameBorder = new
-            BorderUIResource.CompoundBorderUIResource(
-                BorderFactory.createBevelBorder(BevelBorder.RAISED,
-                    table.getColor("InternalFrame.borderColor"),
-                    table.getColor("InternalFrame.borderHighlight"),
-                    table.getColor("InternalFrame.borderDarkShadow"),
-                    table.getColor("InternalFrame.borderShadow")),
-                new WindowsBorders.InternalFrameLineBorder(
-                    table.getColor("InternalFrame.activeBorderColor"),
-                    table.getColor("InternalFrame.inactiveBorderColor"),
-                    table.getInt("InternalFrame.borderWidth")));
-
-        return internalFrameBorder;
-    }
-
-    @SuppressWarnings("serial") // Superclass is not serializable across versions
-    public static class ProgressBarBorder extends AbstractBorder implements UIResource {
-        protected Color shadow;
-        protected Color highlight;
-
-        public ProgressBarBorder(Color shadow, Color highlight) {
-            this.highlight = highlight;
-            this.shadow = shadow;
-        }
-
-        public void paintBorder(Component c, Graphics g, int x, int y,
-                                int width, int height) {
-            g.setColor(shadow);
-            g.drawLine(x,y, width-1,y); // draw top
-            g.drawLine(x,y, x,height-1); // draw left
-            g.setColor(highlight);
-            g.drawLine(x,height-1, width-1,height-1); // draw bottom
-            g.drawLine(width-1,y, width-1,height-1); // draw right
-        }
-
-        public Insets getBorderInsets(Component c, Insets insets) {
-            insets.set(1,1,1,1);
-            return insets;
-        }
-    }
-
-    /**
-     * A border for the ToolBar. If the ToolBar is floatable then the handle grip is drawn
-     *
-     * @since 1.4
-     */
-    @SuppressWarnings("serial") // Superclass is not serializable across versions
-    public static class ToolBarBorder extends AbstractBorder implements UIResource, SwingConstants {
-        protected Color shadow;
-        protected Color highlight;
-
-        public ToolBarBorder(Color shadow, Color highlight) {
-            this.highlight = highlight;
-            this.shadow = shadow;
-        }
-
-        public void paintBorder(Component c, Graphics g, int x, int y,
-                                int width, int height) {
-            if (!(c instanceof JToolBar)) {
-                return;
-            }
-            g.translate(x, y);
-
-            XPStyle xp = XPStyle.getXP();
-            if (xp != null) {
-                Border xpBorder = xp.getBorder(c, Part.TP_TOOLBAR);
-                if (xpBorder != null) {
-                    xpBorder.paintBorder(c, g, 0, 0, width, height);
-                }
-            }
-            if (((JToolBar)c).isFloatable()) {
-                boolean vertical = ((JToolBar)c).getOrientation() == VERTICAL;
-
-                if (xp != null) {
-                    Part part = vertical ? Part.RP_GRIPPERVERT : Part.RP_GRIPPER;
-                    Skin skin = xp.getSkin(c, part);
-                    int dx, dy, dw, dh;
-                    if (vertical) {
-                        dx = 0;
-                        dy = 2;
-                        dw = width - 1;
-                        dh = skin.getHeight();
-                    } else {
-                        dw = skin.getWidth();
-                        dh = height - 1;
-                        dx = c.getComponentOrientation().isLeftToRight() ? 2 : (width-dw-2);
-                        dy = 0;
-                    }
-                    skin.paintSkin(g, dx, dy, dw, dh, State.NORMAL);
-
-                } else {
-
-                    if (!vertical) {
-                        if (c.getComponentOrientation().isLeftToRight()) {
-                            g.setColor(shadow);
-                            g.drawLine(4, 3, 4, height - 4);
-                            g.drawLine(4, height - 4, 2, height - 4);
-
-                            g.setColor(highlight);
-                            g.drawLine(2, 3, 3, 3);
-                            g.drawLine(2, 3, 2, height - 5);
-                        } else {
-                            g.setColor(shadow);
-                            g.drawLine(width - 3, 3, width - 3, height - 4);
-                            g.drawLine(width - 4, height - 4, width - 4, height - 4);
-
-                            g.setColor(highlight);
-                            g.drawLine(width - 5, 3, width - 4, 3);
-                            g.drawLine(width - 5, 3, width - 5, height - 5);
-                        }
-                    } else { // Vertical
-                        g.setColor(shadow);
-                        g.drawLine(3, 4, width - 4, 4);
-                        g.drawLine(width - 4, 2, width - 4, 4);
-
-                        g.setColor(highlight);
-                        g.drawLine(3, 2, width - 4, 2);
-                        g.drawLine(3, 2, 3, 3);
-                    }
-                }
-            }
-
-            g.translate(-x, -y);
-        }
-
-        public Insets getBorderInsets(Component c, Insets insets) {
-            insets.set(1,1,1,1);
-            if (!(c instanceof JToolBar)) {
-                return insets;
-            }
-            if (((JToolBar)c).isFloatable()) {
-                int gripInset = (XPStyle.getXP() != null) ? 12 : 9;
-                if (((JToolBar)c).getOrientation() == HORIZONTAL) {
-                    if (c.getComponentOrientation().isLeftToRight()) {
-                        insets.left = gripInset;
-                    } else {
-                        insets.right = gripInset;
-                    }
-                } else {
-                    insets.top = gripInset;
-                }
-            }
-            return insets;
-        }
-    }
-
-    /**
-     * This class is an implementation of a dashed border.
-     * @since 1.4
-     */
-    @SuppressWarnings("serial") // Superclass is not serializable across versions
-    public static class DashedBorder extends LineBorder implements UIResource {
-        public DashedBorder(Color color) {
-            super(color);
-        }
-
-        public DashedBorder(Color color, int thickness)  {
-            super(color, thickness);
-        }
-
-        public void paintBorder(Component c, Graphics g, int x, int y, int width, int height) {
-            Color oldColor = g.getColor();
-            int i;
-
-            g.setColor(lineColor);
-            for(i = 0; i < thickness; i++)  {
-                BasicGraphicsUtils.drawDashedRect(g, x+i, y+i, width-i-i, height-i-i);
-            }
-            g.setColor(oldColor);
-        }
-    }
-
-    /**
-     * A dashed border that paints itself in the complementary color
-     * of the component's background color.
-     */
-    @SuppressWarnings("serial") // Superclass is not serializable across versions
-    static class ComplementDashedBorder extends LineBorder implements UIResource {
-        private Color origColor;
-        private Color paintColor;
-
-        public ComplementDashedBorder() {
-            super(null);
-        }
-
-        public void paintBorder(Component c, Graphics g, int x, int y, int width, int height) {
-            Color color = c.getBackground();
-
-            if (origColor != color) {
-                origColor = color;
-                paintColor = new Color(~origColor.getRGB());
-            }
-
-            g.setColor(paintColor);
-            BasicGraphicsUtils.drawDashedRect(g, x, y, width, height);
-        }
-    }
-
-    /**
-     * This class is an implementation of the InternalFrameLine border.
-     * @since 1.4
-     */
-    @SuppressWarnings("serial") // Superclass is not serializable across versions
-    public static class InternalFrameLineBorder extends LineBorder implements
-            UIResource {
-        protected Color activeColor;
-        protected Color inactiveColor;
-
-        public InternalFrameLineBorder(Color activeBorderColor,
-                                       Color inactiveBorderColor,
-                                       int thickness) {
-            super(activeBorderColor, thickness);
-            activeColor = activeBorderColor;
-            inactiveColor = inactiveBorderColor;
-        }
-
-        public void paintBorder(Component c, Graphics g, int x, int y,
-                int width, int height) {
-
-            JInternalFrame jif = null;
-            if (c instanceof JInternalFrame) {
-                jif = (JInternalFrame)c;
-            } else if (c instanceof JInternalFrame.JDesktopIcon) {
-                jif = ((JInternalFrame.JDesktopIcon)c).getInternalFrame();
-            } else {
-                return;
-            }
-
-            if (jif.isSelected()) {
-                // Set the line color so the line border gets the correct
-                // color.
-                lineColor = activeColor;
-                super.paintBorder(c, g, x, y, width, height);
-            } else {
-                lineColor = inactiveColor;
-                super.paintBorder(c, g, x, y, width, height);
-            }
-        }
-    }
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsButtonListener.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,54 +0,0 @@
-/*
- * Copyright (c) 1998, 2006, 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.
- */
-
-
-package com.sun.java.swing.plaf.windows;
-
-import java.beans.PropertyChangeEvent;
-
-import javax.swing.*;
-import javax.swing.plaf.basic.*;
-
-/**
- * Button Listener
- * <p>
- * <strong>Warning:</strong>
- * Serialized objects of this class will not be compatible with
- * future Swing releases.  The current serialization support is appropriate
- * for short term storage or RMI between applications running the same
- * version of Swing.  A future release of Swing will provide support for
- * long term persistence.
- *
- * @author Rich Schiavi
- */
-public class WindowsButtonListener extends BasicButtonListener {
-    public WindowsButtonListener(AbstractButton b) {
-        super(b);
-    }
-    /*
-     This class is currently not used, but exists in case customers
-     were subclassing it.
-     */
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsButtonUI.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,321 +0,0 @@
-/*
- * Copyright (c) 1997, 2006, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import javax.swing.plaf.basic.*;
-import javax.swing.border.*;
-import javax.swing.plaf.*;
-import javax.swing.*;
-
-import java.awt.*;
-
-import static com.sun.java.swing.plaf.windows.TMSchema.*;
-import static com.sun.java.swing.plaf.windows.TMSchema.Part.*;
-import static com.sun.java.swing.plaf.windows.XPStyle.Skin;
-import sun.awt.AppContext;
-
-
-/**
- * Windows button.
- * <p>
- * <strong>Warning:</strong>
- * Serialized objects of this class will not be compatible with
- * future Swing releases.  The current serialization support is appropriate
- * for short term storage or RMI between applications running the same
- * version of Swing.  A future release of Swing will provide support for
- * long term persistence.
- *
- * @author Jeff Dinkins
- *
- */
-public class WindowsButtonUI extends BasicButtonUI
-{
-    protected int dashedRectGapX;
-    protected int dashedRectGapY;
-    protected int dashedRectGapWidth;
-    protected int dashedRectGapHeight;
-
-    protected Color focusColor;
-
-    private boolean defaults_initialized = false;
-
-    private static final Object WINDOWS_BUTTON_UI_KEY = new Object();
-
-    // ********************************
-    //          Create PLAF
-    // ********************************
-    public static ComponentUI createUI(JComponent c) {
-        AppContext appContext = AppContext.getAppContext();
-        WindowsButtonUI windowsButtonUI =
-                (WindowsButtonUI) appContext.get(WINDOWS_BUTTON_UI_KEY);
-        if (windowsButtonUI == null) {
-            windowsButtonUI = new WindowsButtonUI();
-            appContext.put(WINDOWS_BUTTON_UI_KEY, windowsButtonUI);
-        }
-        return windowsButtonUI;
-    }
-
-
-    // ********************************
-    //            Defaults
-    // ********************************
-    protected void installDefaults(AbstractButton b) {
-        super.installDefaults(b);
-        if(!defaults_initialized) {
-            String pp = getPropertyPrefix();
-            dashedRectGapX = UIManager.getInt(pp + "dashedRectGapX");
-            dashedRectGapY = UIManager.getInt(pp + "dashedRectGapY");
-            dashedRectGapWidth = UIManager.getInt(pp + "dashedRectGapWidth");
-            dashedRectGapHeight = UIManager.getInt(pp + "dashedRectGapHeight");
-            focusColor = UIManager.getColor(pp + "focus");
-            defaults_initialized = true;
-        }
-
-        XPStyle xp = XPStyle.getXP();
-        if (xp != null) {
-            b.setBorder(xp.getBorder(b, getXPButtonType(b)));
-            LookAndFeel.installProperty(b, "rolloverEnabled", Boolean.TRUE);
-        }
-    }
-
-    protected void uninstallDefaults(AbstractButton b) {
-        super.uninstallDefaults(b);
-        defaults_initialized = false;
-    }
-
-    protected Color getFocusColor() {
-        return focusColor;
-    }
-
-    // ********************************
-    //         Paint Methods
-    // ********************************
-
-    /**
-     * Overridden method to render the text without the mnemonic
-     */
-    protected void paintText(Graphics g, AbstractButton b, Rectangle textRect, String text) {
-        WindowsGraphicsUtils.paintText(g, b, textRect, text, getTextShiftOffset());
-    }
-
-    protected void paintFocus(Graphics g, AbstractButton b, Rectangle viewRect, Rectangle textRect, Rectangle iconRect){
-
-        // focus painted same color as text on Basic??
-        int width = b.getWidth();
-        int height = b.getHeight();
-        g.setColor(getFocusColor());
-        BasicGraphicsUtils.drawDashedRect(g, dashedRectGapX, dashedRectGapY,
-                                          width - dashedRectGapWidth, height - dashedRectGapHeight);
-    }
-
-    protected void paintButtonPressed(Graphics g, AbstractButton b){
-        setTextShiftOffset();
-    }
-
-    // ********************************
-    //          Layout Methods
-    // ********************************
-    public Dimension getPreferredSize(JComponent c) {
-        Dimension d = super.getPreferredSize(c);
-
-        /* Ensure that the width and height of the button is odd,
-         * to allow for the focus line if focus is painted
-         */
-        AbstractButton b = (AbstractButton)c;
-        if (d != null && b.isFocusPainted()) {
-            if(d.width % 2 == 0) { d.width += 1; }
-            if(d.height % 2 == 0) { d.height += 1; }
-        }
-        return d;
-    }
-
-
-    /* These rectangles/insets are allocated once for all
-     * ButtonUI.paint() calls.  Re-using rectangles rather than
-     * allocating them in each paint call substantially reduced the time
-     * it took paint to run.  Obviously, this method can't be re-entered.
-     */
-    private Rectangle viewRect = new Rectangle();
-
-    public void paint(Graphics g, JComponent c) {
-        if (XPStyle.getXP() != null) {
-            WindowsButtonUI.paintXPButtonBackground(g, c);
-        }
-        super.paint(g, c);
-    }
-
-    static Part getXPButtonType(AbstractButton b) {
-        if(b instanceof JCheckBox) {
-            return Part.BP_CHECKBOX;
-        }
-        if(b instanceof JRadioButton) {
-            return Part.BP_RADIOBUTTON;
-        }
-        boolean toolbar = (b.getParent() instanceof JToolBar);
-        return toolbar ? Part.TP_BUTTON : Part.BP_PUSHBUTTON;
-    }
-
-    static State getXPButtonState(AbstractButton b) {
-        Part part = getXPButtonType(b);
-        ButtonModel model = b.getModel();
-        State state = State.NORMAL;
-        switch (part) {
-        case BP_RADIOBUTTON:
-            /* falls through */
-        case BP_CHECKBOX:
-            if (! model.isEnabled()) {
-                state = (model.isSelected()) ? State.CHECKEDDISABLED
-                    : State.UNCHECKEDDISABLED;
-            } else if (model.isPressed() && model.isArmed()) {
-                state = (model.isSelected()) ? State.CHECKEDPRESSED
-                    : State.UNCHECKEDPRESSED;
-            } else if (model.isRollover()) {
-                state = (model.isSelected()) ? State.CHECKEDHOT
-                    : State.UNCHECKEDHOT;
-            } else {
-                state = (model.isSelected()) ? State.CHECKEDNORMAL
-                    : State.UNCHECKEDNORMAL;
-            }
-            break;
-        case BP_PUSHBUTTON:
-            /* falls through */
-        case TP_BUTTON:
-            boolean toolbar = (b.getParent() instanceof JToolBar);
-            if (toolbar) {
-                if (model.isArmed() && model.isPressed()) {
-                    state = State.PRESSED;
-                } else if (!model.isEnabled()) {
-                    state = State.DISABLED;
-                } else if (model.isSelected() && model.isRollover()) {
-                    state = State.HOTCHECKED;
-                } else if (model.isSelected()) {
-                    state = State.CHECKED;
-                } else if (model.isRollover()) {
-                    state = State.HOT;
-                } else if (b.hasFocus()) {
-                    state = State.HOT;
-                }
-            } else {
-                if ((model.isArmed() && model.isPressed())
-                      || model.isSelected()) {
-                    state = State.PRESSED;
-                } else if (!model.isEnabled()) {
-                    state = State.DISABLED;
-                } else if (model.isRollover() || model.isPressed()) {
-                    state = State.HOT;
-                } else if (b instanceof JButton
-                           && ((JButton)b).isDefaultButton()) {
-                    state = State.DEFAULTED;
-                } else if (b.hasFocus()) {
-                    state = State.HOT;
-                }
-            }
-            break;
-        default :
-            state = State.NORMAL;
-        }
-
-        return state;
-    }
-
-    static void paintXPButtonBackground(Graphics g, JComponent c) {
-        AbstractButton b = (AbstractButton)c;
-
-        XPStyle xp = XPStyle.getXP();
-
-        Part part = getXPButtonType(b);
-
-        if (b.isContentAreaFilled() && b.getBorder() != null
-                && b.isBorderPainted() && xp != null) {
-
-            Skin skin = xp.getSkin(b, part);
-
-            State state = getXPButtonState(b);
-            Dimension d = c.getSize();
-            int dx = 0;
-            int dy = 0;
-            int dw = d.width;
-            int dh = d.height;
-
-            Border border = c.getBorder();
-            Insets insets;
-            if (border != null) {
-                // Note: The border may be compound, containing an outer
-                // opaque border (supplied by the application), plus an
-                // inner transparent margin border. We want to size the
-                // background to fill the transparent part, but stay
-                // inside the opaque part.
-                insets = WindowsButtonUI.getOpaqueInsets(border, c);
-            } else {
-                insets = c.getInsets();
-            }
-            if (insets != null) {
-                dx += insets.left;
-                dy += insets.top;
-                dw -= (insets.left + insets.right);
-                dh -= (insets.top + insets.bottom);
-            }
-            skin.paintSkin(g, dx, dy, dw, dh, state);
-        }
-    }
-
-    /**
-     * returns - b.getBorderInsets(c) if border is opaque
-     *         - null if border is completely non-opaque
-     *         - somewhere inbetween if border is compound and
-     *              outside border is opaque and inside isn't
-     */
-    private static Insets getOpaqueInsets(Border b, Component c) {
-        if (b == null) {
-            return null;
-        }
-        if (b.isBorderOpaque()) {
-            return b.getBorderInsets(c);
-        } else if (b instanceof CompoundBorder) {
-            CompoundBorder cb = (CompoundBorder)b;
-            Insets iOut = getOpaqueInsets(cb.getOutsideBorder(), c);
-            if (iOut != null && iOut.equals(cb.getOutsideBorder().getBorderInsets(c))) {
-                // Outside border is opaque, keep looking
-                Insets iIn = getOpaqueInsets(cb.getInsideBorder(), c);
-                if (iIn == null) {
-                    // Inside is non-opaque, use outside insets
-                    return iOut;
-                } else {
-                    // Found non-opaque somewhere in the inside (which is
-                    // also compound).
-                    return new Insets(iOut.top + iIn.top, iOut.left + iIn.left,
-                                      iOut.bottom + iIn.bottom, iOut.right + iIn.right);
-                }
-            } else {
-                // Outside is either all non-opaque or has non-opaque
-                // border inside another compound border
-                return iOut;
-            }
-        } else {
-            return null;
-        }
-    }
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsCheckBoxMenuItemUI.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,104 +0,0 @@
-/*
- * Copyright (c) 1997, 2006, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import java.awt.*;
-import javax.swing.*;
-import javax.swing.plaf.*;
-import javax.swing.plaf.basic.*;
-
-import com.sun.java.swing.plaf.windows.TMSchema.Part;
-import com.sun.java.swing.plaf.windows.TMSchema.State;
-
-
-/**
- * Windows check box menu item.
- * <p>
- * <strong>Warning:</strong>
- * Serialized objects of this class will not be compatible with
- * future Swing releases.  The current serialization support is appropriate
- * for short term storage or RMI between applications running the same
- * version of Swing.  A future release of Swing will provide support for
- * long term persistence.
- */
-public class WindowsCheckBoxMenuItemUI extends BasicCheckBoxMenuItemUI {
-
-    final WindowsMenuItemUIAccessor accessor =
-        new WindowsMenuItemUIAccessor() {
-
-            public JMenuItem getMenuItem() {
-                return menuItem;
-            }
-
-            public State getState(JMenuItem menuItem) {
-                return WindowsMenuItemUI.getState(this, menuItem);
-            }
-
-            public Part getPart(JMenuItem menuItem) {
-                return WindowsMenuItemUI.getPart(this, menuItem);
-            }
-    };
-    public static ComponentUI createUI(JComponent b) {
-        return new WindowsCheckBoxMenuItemUI();
-    }
-
-    @Override
-    protected  void paintBackground(Graphics g, JMenuItem menuItem,
-            Color bgColor) {
-        if (WindowsMenuItemUI.isVistaPainting()) {
-            WindowsMenuItemUI.paintBackground(accessor, g, menuItem, bgColor);
-            return;
-        }
-        super.paintBackground(g, menuItem, bgColor);
-    }
-    /**
-     * Method which renders the text of the current menu item.
-     *
-     * @param g Graphics context
-     * @param menuItem Current menu item to render
-     * @param textRect Bounding rectangle to render the text.
-     * @param text String to render
-     * @since 1.4
-     */
-    protected void paintText(Graphics g, JMenuItem menuItem,
-                             Rectangle textRect, String text) {
-        if (WindowsMenuItemUI.isVistaPainting()) {
-            WindowsMenuItemUI.paintText(accessor, g, menuItem,
-                                        textRect, text);
-            return;
-        }
-        ButtonModel model = menuItem.getModel();
-        Color oldColor = g.getColor();
-
-        if(model.isEnabled() && model.isArmed()) {
-            g.setColor(selectionForeground); // Uses protected field.
-        }
-
-        WindowsGraphicsUtils.paintText(g, menuItem, textRect, text, 0);
-
-        g.setColor(oldColor);
-    }
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsCheckBoxUI.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,95 +0,0 @@
-/*
- * Copyright (c) 1997, 1998, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import sun.awt.AppContext;
-
-import javax.swing.plaf.basic.*;
-import javax.swing.*;
-import javax.swing.plaf.*;
-
-import java.awt.*;
-
-/**
- * Windows check box.
- * <p>
- * <strong>Warning:</strong>
- * Serialized objects of this class will not be compatible with
- * future Swing releases.  The current serialization support is appropriate
- * for short term storage or RMI between applications running the same
- * version of Swing.  A future release of Swing will provide support for
- * long term persistence.
- *
- * @author Jeff Dinkins
- */
-public class WindowsCheckBoxUI extends WindowsRadioButtonUI
-{
-    // NOTE: MetalCheckBoxUI inherts from MetalRadioButtonUI instead
-    // of BasicCheckBoxUI because we want to pick up all the
-    // painting changes made in MetalRadioButtonUI.
-
-    private static final Object WINDOWS_CHECK_BOX_UI_KEY = new Object();
-
-    private static final String propertyPrefix = "CheckBox" + ".";
-
-    private boolean defaults_initialized = false;
-
-    // ********************************
-    //          Create PLAF
-    // ********************************
-    public static ComponentUI createUI(JComponent c) {
-        AppContext appContext = AppContext.getAppContext();
-        WindowsCheckBoxUI windowsCheckBoxUI =
-                (WindowsCheckBoxUI) appContext.get(WINDOWS_CHECK_BOX_UI_KEY);
-        if (windowsCheckBoxUI == null) {
-            windowsCheckBoxUI = new WindowsCheckBoxUI();
-            appContext.put(WINDOWS_CHECK_BOX_UI_KEY, windowsCheckBoxUI);
-        }
-        return windowsCheckBoxUI;
-    }
-
-
-    public String getPropertyPrefix() {
-        return propertyPrefix;
-    }
-
-    // ********************************
-    //          Defaults
-    // ********************************
-    public void installDefaults(AbstractButton b) {
-        super.installDefaults(b);
-        if(!defaults_initialized) {
-            icon = UIManager.getIcon(getPropertyPrefix() + "icon");
-            defaults_initialized = true;
-        }
-    }
-
-    public void uninstallDefaults(AbstractButton b) {
-        super.uninstallDefaults(b);
-        defaults_initialized = false;
-    }
-
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsClassicLookAndFeel.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,45 +0,0 @@
-/*
- * Copyright (c) 2003, 2014, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-/**
- * Implements the Windows95/98/ME/NT/2000 Look and Feel.
- * <p>
- * <strong>Warning:</strong>
- * Serialized objects of this class will not be compatible with
- * future Swing releases.  The current serialization support is appropriate
- * for short term storage or RMI between applications running the same
- * version of Swing.  A future release of Swing will provide support for
- * long term persistence.
- *
- * @since 1.5
- */
-@SuppressWarnings("serial") // Superclass is not serializable across versions
-public class WindowsClassicLookAndFeel extends WindowsLookAndFeel {
-    public String getName() {
-        return "Windows Classic";
-    }
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsComboBoxUI.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,665 +0,0 @@
-/*
- * Copyright (c) 1997, 2014, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import java.beans.PropertyChangeListener;
-import java.beans.PropertyChangeEvent;
-import javax.swing.plaf.basic.*;
-import javax.swing.plaf.*;
-import javax.swing.border.*;
-import javax.swing.*;
-import java.awt.event.*;
-import java.awt.*;
-
-import static com.sun.java.swing.plaf.windows.TMSchema.Part;
-import static com.sun.java.swing.plaf.windows.TMSchema.State;
-import static com.sun.java.swing.plaf.windows.XPStyle.Skin;
-
-import sun.swing.DefaultLookup;
-import sun.swing.StringUIClientPropertyKey;
-
-import com.sun.java.swing.plaf.windows.WindowsBorders.DashedBorder;
-
-/**
- * Windows combo box.
- * <p>
- * <strong>Warning:</strong>
- * Serialized objects of this class will not be compatible with
- * future Swing releases.  The current serialization support is appropriate
- * for short term storage or RMI between applications running the same
- * version of Swing.  A future release of Swing will provide support for
- * long term persistence.
- *
- * @author Tom Santos
- * @author Igor Kushnirskiy
- */
-
-public class WindowsComboBoxUI extends BasicComboBoxUI {
-
-    private static final MouseListener rolloverListener =
-        new MouseAdapter() {
-            private void handleRollover(MouseEvent e, boolean isRollover) {
-                JComboBox<?> comboBox = getComboBox(e);
-                WindowsComboBoxUI comboBoxUI = getWindowsComboBoxUI(e);
-                if (comboBox == null || comboBoxUI == null) {
-                    return;
-                }
-                if (! comboBox.isEditable()) {
-                    //mouse over editable ComboBox does not switch rollover
-                    //for the arrow button
-                    ButtonModel m = null;
-                    if (comboBoxUI.arrowButton != null) {
-                        m = comboBoxUI.arrowButton.getModel();
-                    }
-                    if (m != null ) {
-                        m.setRollover(isRollover);
-                    }
-                }
-                comboBoxUI.isRollover = isRollover;
-                comboBox.repaint();
-            }
-
-            public void mouseEntered(MouseEvent e) {
-                handleRollover(e, true);
-            }
-
-            public void mouseExited(MouseEvent e) {
-                handleRollover(e, false);
-            }
-
-            private JComboBox<?> getComboBox(MouseEvent event) {
-                Object source = event.getSource();
-                JComboBox<?> rv = null;
-                if (source instanceof JComboBox) {
-                    rv = (JComboBox) source;
-                } else if (source instanceof XPComboBoxButton) {
-                    rv = ((XPComboBoxButton) source)
-                        .getWindowsComboBoxUI().comboBox;
-                } else if (source instanceof JTextField &&
-                        ((JTextField) source).getParent() instanceof JComboBox) {
-                    rv = (JComboBox) ((JTextField) source).getParent();
-                }
-                return rv;
-            }
-
-            private WindowsComboBoxUI getWindowsComboBoxUI(MouseEvent event) {
-                JComboBox<?> comboBox = getComboBox(event);
-                WindowsComboBoxUI rv = null;
-                if (comboBox != null
-                    && comboBox.getUI() instanceof WindowsComboBoxUI) {
-                    rv = (WindowsComboBoxUI) comboBox.getUI();
-                }
-                return rv;
-            }
-
-        };
-    private boolean isRollover = false;
-
-    private static final PropertyChangeListener componentOrientationListener =
-        new PropertyChangeListener() {
-            public void propertyChange(PropertyChangeEvent e) {
-                String propertyName = e.getPropertyName();
-                Object source = null;
-                if ("componentOrientation" == propertyName
-                    && (source = e.getSource()) instanceof JComboBox
-                    && ((JComboBox) source).getUI() instanceof
-                      WindowsComboBoxUI) {
-                    JComboBox<?> comboBox = (JComboBox) source;
-                    WindowsComboBoxUI comboBoxUI = (WindowsComboBoxUI) comboBox.getUI();
-                    if (comboBoxUI.arrowButton instanceof XPComboBoxButton) {
-                        ((XPComboBoxButton) comboBoxUI.arrowButton).setPart(
-                                    (comboBox.getComponentOrientation() ==
-                                       ComponentOrientation.RIGHT_TO_LEFT)
-                                    ? Part.CP_DROPDOWNBUTTONLEFT
-                                    : Part.CP_DROPDOWNBUTTONRIGHT);
-                            }
-                        }
-                    }
-                };
-
-    public static ComponentUI createUI(JComponent c) {
-        return new WindowsComboBoxUI();
-    }
-
-    public void installUI( JComponent c ) {
-        super.installUI( c );
-        isRollover = false;
-        comboBox.setRequestFocusEnabled( true );
-        if (XPStyle.getXP() != null && arrowButton != null) {
-            //we can not do it in installListeners because arrowButton
-            //is initialized after installListeners is invoked
-            comboBox.addMouseListener(rolloverListener);
-            arrowButton.addMouseListener(rolloverListener);
-            // set empty border as default to see vista animated border
-            comboBox.setBorder(new EmptyBorder(0,0,0,0));
-        }
-    }
-
-    public void uninstallUI(JComponent c ) {
-        comboBox.removeMouseListener(rolloverListener);
-        if(arrowButton != null) {
-            arrowButton.removeMouseListener(rolloverListener);
-        }
-        super.uninstallUI( c );
-    }
-
-    /**
-     * {@inheritDoc}
-     * @since 1.6
-     */
-    @Override
-    protected void installListeners() {
-        super.installListeners();
-        XPStyle xp = XPStyle.getXP();
-        //button glyph for LTR and RTL combobox might differ
-        if (xp != null
-              && xp.isSkinDefined(comboBox, Part.CP_DROPDOWNBUTTONRIGHT)) {
-            comboBox.addPropertyChangeListener("componentOrientation",
-                                               componentOrientationListener);
-        }
-    }
-
-    /**
-     * {@inheritDoc}
-     * @since 1.6
-     */
-    @Override
-    protected void uninstallListeners() {
-        super.uninstallListeners();
-        comboBox.removePropertyChangeListener("componentOrientation",
-                                              componentOrientationListener);
-    }
-
-    /**
-     * {@inheritDoc}
-     * @since 1.6
-     */
-    protected void configureEditor() {
-        super.configureEditor();
-        if (XPStyle.getXP() != null) {
-            editor.addMouseListener(rolloverListener);
-        }
-    }
-
-    /**
-     * {@inheritDoc}
-     * @since 1.6
-     */
-    protected void unconfigureEditor() {
-        super.unconfigureEditor();
-        editor.removeMouseListener(rolloverListener);
-    }
-
-    /**
-     * {@inheritDoc}
-     * @since 1.6
-     */
-    public void paint(Graphics g, JComponent c) {
-        if (XPStyle.getXP() != null) {
-            paintXPComboBoxBackground(g, c);
-        }
-        super.paint(g, c);
-    }
-
-    State getXPComboBoxState(JComponent c) {
-        State state = State.NORMAL;
-        if (!c.isEnabled()) {
-            state = State.DISABLED;
-        } else if (isPopupVisible(comboBox)) {
-            state = State.PRESSED;
-        } else if (comboBox.isEditable()
-                && comboBox.getEditor().getEditorComponent().isFocusOwner()) {
-            state = State.PRESSED;
-        } else if (isRollover) {
-            state = State.HOT;
-        }
-        return state;
-    }
-
-    private void paintXPComboBoxBackground(Graphics g, JComponent c) {
-        XPStyle xp = XPStyle.getXP();
-        if (xp == null) {
-            return;
-        }
-        State state = getXPComboBoxState(c);
-        Skin skin = null;
-        if (! comboBox.isEditable()
-              && xp.isSkinDefined(c, Part.CP_READONLY)) {
-            skin = xp.getSkin(c, Part.CP_READONLY);
-        }
-        if (skin == null) {
-            skin = xp.getSkin(c, Part.CP_BORDER);
-        }
-        skin.paintSkin(g, 0, 0, c.getWidth(), c.getHeight(), state);
-    }
-
-    /**
-     * If necessary paints the currently selected item.
-     *
-     * @param g Graphics to paint to
-     * @param bounds Region to paint current value to
-     * @param hasFocus whether or not the JComboBox has focus
-     * @throws NullPointerException if any of the arguments are null.
-     * @since 1.5
-     */
-    public void paintCurrentValue(Graphics g, Rectangle bounds,
-                                  boolean hasFocus) {
-        XPStyle xp = XPStyle.getXP();
-        if ( xp != null) {
-            bounds.x += 2;
-            bounds.y += 2;
-            bounds.width -= 4;
-            bounds.height -= 4;
-        } else {
-            bounds.x += 1;
-            bounds.y += 1;
-            bounds.width -= 2;
-            bounds.height -= 2;
-        }
-        if (! comboBox.isEditable()
-            && xp != null
-            && xp.isSkinDefined(comboBox, Part.CP_READONLY)) {
-            // On vista for READNLY ComboBox
-            // color for currentValue is the same as for any other item
-
-            // mostly copied from javax.swing.plaf.basic.BasicComboBoxUI.paintCurrentValue
-            ListCellRenderer<Object> renderer = comboBox.getRenderer();
-            Component c;
-            if ( hasFocus && !isPopupVisible(comboBox) ) {
-                c = renderer.getListCellRendererComponent(
-                        listBox,
-                        comboBox.getSelectedItem(),
-                        -1,
-                        true,
-                        false );
-            } else {
-                c = renderer.getListCellRendererComponent(
-                        listBox,
-                        comboBox.getSelectedItem(),
-                        -1,
-                        false,
-                        false );
-            }
-            c.setFont(comboBox.getFont());
-            if ( comboBox.isEnabled() ) {
-                c.setForeground(comboBox.getForeground());
-                c.setBackground(comboBox.getBackground());
-            } else {
-                c.setForeground(DefaultLookup.getColor(
-                         comboBox, this, "ComboBox.disabledForeground", null));
-                c.setBackground(DefaultLookup.getColor(
-                         comboBox, this, "ComboBox.disabledBackground", null));
-            }
-            boolean shouldValidate = false;
-            if (c instanceof JPanel)  {
-                shouldValidate = true;
-            }
-            currentValuePane.paintComponent(g, c, comboBox, bounds.x, bounds.y,
-                                            bounds.width, bounds.height, shouldValidate);
-
-        } else {
-            super.paintCurrentValue(g, bounds, hasFocus);
-        }
-    }
-
-    /**
-     * {@inheritDoc}
-     * @since 1.6
-     */
-    public void paintCurrentValueBackground(Graphics g, Rectangle bounds,
-                                            boolean hasFocus) {
-        if (XPStyle.getXP() == null) {
-            super.paintCurrentValueBackground(g, bounds, hasFocus);
-        }
-    }
-
-    public Dimension getMinimumSize( JComponent c ) {
-        Dimension d = super.getMinimumSize(c);
-        if (XPStyle.getXP() != null) {
-            d.width += 7;
-            boolean isEditable = false;
-            if (c instanceof JComboBox) {
-                isEditable = ((JComboBox) c).isEditable();
-            }
-            d.height += isEditable ? 4 : 6;
-        } else {
-            d.width += 4;
-            d.height += 2;
-        }
-        return d;
-    }
-
-    /**
-     * Creates a layout manager for managing the components which make up the
-     * combo box.
-     *
-     * @return an instance of a layout manager
-     */
-    protected LayoutManager createLayoutManager() {
-        return new BasicComboBoxUI.ComboBoxLayoutManager() {
-            public void layoutContainer(Container parent) {
-                super.layoutContainer(parent);
-
-                if (XPStyle.getXP() != null && arrowButton != null) {
-                    Dimension d = parent.getSize();
-                    Insets insets = getInsets();
-                    int buttonWidth = arrowButton.getPreferredSize().width;
-                    arrowButton.setBounds(WindowsGraphicsUtils.isLeftToRight((JComboBox)parent)
-                                          ? (d.width - insets.right - buttonWidth)
-                                          : insets.left,
-                                          insets.top,
-                                          buttonWidth, d.height - insets.top - insets.bottom);
-                }
-            }
-        };
-    }
-
-    protected void installKeyboardActions() {
-        super.installKeyboardActions();
-    }
-
-    protected ComboPopup createPopup() {
-        return new WinComboPopUp(comboBox);
-    }
-
-    /**
-     * Creates the default editor that will be used in editable combo boxes.
-     * A default editor will be used only if an editor has not been
-     * explicitly set with <code>setEditor</code>.
-     *
-     * @return a <code>ComboBoxEditor</code> used for the combo box
-     * @see javax.swing.JComboBox#setEditor
-     */
-    protected ComboBoxEditor createEditor() {
-        return new WindowsComboBoxEditor();
-    }
-
-    /**
-     * {@inheritDoc}
-     * @since 1.6
-     */
-    @Override
-    protected ListCellRenderer<Object> createRenderer() {
-        XPStyle xp = XPStyle.getXP();
-        if (xp != null && xp.isSkinDefined(comboBox, Part.CP_READONLY)) {
-            return new WindowsComboBoxRenderer();
-        } else {
-            return super.createRenderer();
-        }
-    }
-
-    /**
-     * Creates an button which will be used as the control to show or hide
-     * the popup portion of the combo box.
-     *
-     * @return a button which represents the popup control
-     */
-    protected JButton createArrowButton() {
-        XPStyle xp = XPStyle.getXP();
-        if (xp != null) {
-            return new XPComboBoxButton(xp);
-        } else {
-            return super.createArrowButton();
-        }
-    }
-
-    @SuppressWarnings("serial") // Superclass is not serializable across versions
-    private class XPComboBoxButton extends XPStyle.GlyphButton {
-        private State prevState = null;
-
-        public XPComboBoxButton(XPStyle xp) {
-            super(comboBox,
-                  (! xp.isSkinDefined(comboBox, Part.CP_DROPDOWNBUTTONRIGHT))
-                   ? Part.CP_DROPDOWNBUTTON
-                   : (comboBox.getComponentOrientation() == ComponentOrientation.RIGHT_TO_LEFT)
-                     ? Part.CP_DROPDOWNBUTTONLEFT
-                     : Part.CP_DROPDOWNBUTTONRIGHT
-                  );
-            setRequestFocusEnabled(false);
-        }
-
-        @Override
-        protected State getState() {
-            State rv;
-
-            getModel().setPressed(comboBox.isPopupVisible());
-
-            rv = super.getState();
-            XPStyle xp = XPStyle.getXP();
-            if (rv != State.DISABLED
-                    && comboBox != null && ! comboBox.isEditable()
-                    && xp != null && xp.isSkinDefined(comboBox,
-                            Part.CP_DROPDOWNBUTTONRIGHT)) {
-                /*
-                 * for non editable ComboBoxes Vista seems to have the
-                 * same glyph for all non DISABLED states
-                 */
-                rv = State.NORMAL;
-            }
-            if (rv == State.NORMAL && (prevState == State.HOT || prevState == State.PRESSED)) {
-                /*
-                 * State NORMAL of combobox button cannot overpaint states HOT or PRESSED
-                 * Therefore HOT state must be painted from alpha 1 to 0 and not as usual that
-                 * NORMAL state is painted from alpha 0 to alpha 1.
-                 */
-                skin.switchStates(true);
-            }
-            if (rv != prevState) {
-                prevState = rv;
-            }
-
-            return rv;
-        }
-
-        public Dimension getPreferredSize() {
-            return new Dimension(17, 21);
-        }
-
-        void setPart(Part part) {
-            setPart(comboBox, part);
-        }
-
-        WindowsComboBoxUI getWindowsComboBoxUI() {
-            return WindowsComboBoxUI.this;
-        }
-    }
-
-
-    /**
-     * Subclassed to add Windows specific Key Bindings.
-     * This class is now obsolete and doesn't do anything.
-     * Only included for backwards API compatibility.
-     * Do not call or override.
-     *
-     * @deprecated As of Java 2 platform v1.4.
-     */
-    @Deprecated
-    @SuppressWarnings("serial") // Superclass is not serializable across versions
-    protected class WindowsComboPopup extends BasicComboPopup {
-
-        public WindowsComboPopup( JComboBox<Object> cBox ) {
-            super( cBox );
-        }
-
-        protected KeyListener createKeyListener() {
-            return new InvocationKeyHandler();
-        }
-
-        protected class InvocationKeyHandler extends BasicComboPopup.InvocationKeyHandler {
-            protected InvocationKeyHandler() {
-                WindowsComboPopup.this.super();
-            }
-        }
-    }
-
-    @SuppressWarnings("serial") // Same-version serialization only
-    protected class WinComboPopUp extends BasicComboPopup {
-        private Skin listBoxBorder = null;
-        private XPStyle xp;
-
-        public WinComboPopUp(JComboBox<Object> combo) {
-            super(combo);
-            xp = XPStyle.getXP();
-            if (xp != null && xp.isSkinDefined(combo, Part.LBCP_BORDER_NOSCROLL)) {
-                this.listBoxBorder = new Skin(combo, Part.LBCP_BORDER_NOSCROLL);
-                this.setBorder(new EmptyBorder(1,1,1,1));
-            }
-        }
-
-        protected KeyListener createKeyListener() {
-            return new InvocationKeyHandler();
-        }
-
-        protected class InvocationKeyHandler extends BasicComboPopup.InvocationKeyHandler {
-            protected InvocationKeyHandler() {
-                WinComboPopUp.this.super();
-            }
-        }
-
-        protected void paintComponent(Graphics g) {
-            super.paintComponent(g);
-            if (this.listBoxBorder != null) {
-                this.listBoxBorder.paintSkinRaw(g, this.getX(), this.getY(),
-                        this.getWidth(), this.getHeight(), State.HOT);
-            }
-        }
-    }
-
-
-    /**
-     * Subclassed to highlight selected item in an editable combo box.
-     */
-    public static class WindowsComboBoxEditor
-        extends BasicComboBoxEditor.UIResource {
-
-        /**
-         * {@inheritDoc}
-         * @since 1.6
-         */
-        protected JTextField createEditorComponent() {
-            JTextField editor = super.createEditorComponent();
-            Border border = (Border)UIManager.get("ComboBox.editorBorder");
-
-            if (border != null) {
-                editor.setBorder(border);
-            }
-            editor.setOpaque(false);
-            return editor;
-        }
-
-        public void setItem(Object item) {
-            super.setItem(item);
-            Object focus = KeyboardFocusManager.getCurrentKeyboardFocusManager().getFocusOwner();
-            if ((focus == editor) || (focus == editor.getParent())) {
-                editor.selectAll();
-            }
-        }
-    }
-
-    /**
-     * Subclassed to set opacity {@code false} on the renderer
-     * and to show border for focused cells.
-     */
-    @SuppressWarnings("serial") // Superclass is not serializable across versions
-    private static class WindowsComboBoxRenderer
-          extends BasicComboBoxRenderer.UIResource {
-        private static final Object BORDER_KEY
-            = new StringUIClientPropertyKey("BORDER_KEY");
-        private static final Border NULL_BORDER = new EmptyBorder(0, 0, 0, 0);
-
-        // Create own version of DashedBorder with more space on left side
-        private class WindowsComboBoxDashedBorder extends DashedBorder {
-
-            public WindowsComboBoxDashedBorder(Color color, int thickness) {
-                super(color, thickness);
-            }
-
-            public WindowsComboBoxDashedBorder(Color color) {
-                super(color);
-            }
-
-            @Override
-            public Insets getBorderInsets(Component c, Insets i) {
-                return new Insets(0,2,0,0);
-            }
-        }
-
-        public WindowsComboBoxRenderer() {
-            super();
-
-            // correct space on the left side of text items in the combo popup list
-            Insets i = getBorder().getBorderInsets(this);
-            setBorder(new EmptyBorder(0, 2, 0, i.right));
-        }
-        /**
-         * {@inheritDoc}
-         */
-        @Override
-        public Component getListCellRendererComponent(
-                                                 JList<?> list,
-                                                 Object value,
-                                                 int index,
-                                                 boolean isSelected,
-                                                 boolean cellHasFocus) {
-            Component rv =
-                super.getListCellRendererComponent(list, value, index,
-                                                   isSelected, cellHasFocus);
-            if (rv instanceof JComponent) {
-                JComponent component = (JComponent) rv;
-                if (index == -1 && isSelected) {
-                    Border border = component.getBorder();
-                    Border dashedBorder =
-                        new WindowsComboBoxDashedBorder(list.getForeground());
-                    component.setBorder(dashedBorder);
-                    //store current border in client property if needed
-                    if (component.getClientProperty(BORDER_KEY) == null) {
-                        component.putClientProperty(BORDER_KEY,
-                                       (border == null) ? NULL_BORDER : border);
-                    }
-                } else {
-                    if (component.getBorder() instanceof
-                          WindowsBorders.DashedBorder) {
-                        Object storedBorder = component.getClientProperty(BORDER_KEY);
-                        if (storedBorder instanceof Border) {
-                            component.setBorder(
-                                (storedBorder == NULL_BORDER) ? null
-                                    : (Border) storedBorder);
-                        }
-                        component.putClientProperty(BORDER_KEY, null);
-                    }
-                }
-                if (index == -1) {
-                    component.setOpaque(false);
-                    component.setForeground(list.getForeground());
-                } else {
-                    component.setOpaque(true);
-                }
-            }
-            return rv;
-        }
-
-    }
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsDesktopIconUI.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,98 +0,0 @@
-/*
- * Copyright (c) 1997, 2004, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import java.awt.*;
-import javax.swing.plaf.*;
-import javax.swing.plaf.basic.*;
-import javax.swing.*;
-import javax.swing.border.*;
-
-
-
-/**
- * Windows icon for a minimized window on the desktop.
- * <p>
- * <strong>Warning:</strong>
- * Serialized objects of this class will not be compatible with
- * future Swing releases.  The current serialization support is appropriate
- * for short term storage or RMI between applications running the same
- * version of Swing.  A future release of Swing will provide support for
- * long term persistence.
- */
-public class WindowsDesktopIconUI extends BasicDesktopIconUI {
-    private int width;
-
-    public static ComponentUI createUI(JComponent c) {
-        return new WindowsDesktopIconUI();
-    }
-
-    public void installDefaults() {
-        super.installDefaults();
-        width = UIManager.getInt("DesktopIcon.width");
-    }
-
-    public void installUI(JComponent c)   {
-        super.installUI(c);
-
-        c.setOpaque(XPStyle.getXP() == null);
-    }
-
-    // Uninstall the listeners added by the WindowsInternalFrameTitlePane
-    public void uninstallUI(JComponent c) {
-        WindowsInternalFrameTitlePane thePane =
-                                        (WindowsInternalFrameTitlePane)iconPane;
-        super.uninstallUI(c);
-        thePane.uninstallListeners();
-    }
-
-    protected void installComponents() {
-        iconPane = new WindowsInternalFrameTitlePane(frame);
-        desktopIcon.setLayout(new BorderLayout());
-        desktopIcon.add(iconPane, BorderLayout.CENTER);
-
-        if (XPStyle.getXP() != null) {
-            desktopIcon.setBorder(null);
-        }
-    }
-
-    public Dimension getPreferredSize(JComponent c) {
-        // Windows desktop icons can not be resized.  Therefore, we should
-        // always return the minimum size of the desktop icon. See
-        // getMinimumSize(JComponent c).
-        return getMinimumSize(c);
-    }
-
-    /**
-     * Windows desktop icons are restricted to a width of 160 pixels by
-     * default.  This value is retrieved by the DesktopIcon.width property.
-     */
-    public Dimension getMinimumSize(JComponent c) {
-        Dimension dim = super.getMinimumSize(c);
-        dim.width = width;
-        return dim;
-    }
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsDesktopManager.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,104 +0,0 @@
-/*
- * Copyright (c) 1998, 2014, 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.
- */
-
-
-package com.sun.java.swing.plaf.windows;
-
-import javax.swing.DefaultDesktopManager;
-import javax.swing.JInternalFrame;
-import javax.swing.JLayeredPane;
-import java.awt.Component;
-import java.awt.Container;
-import java.awt.Dimension;
-import java.beans.PropertyVetoException;
-import java.util.Vector;
-import java.lang.ref.WeakReference;
-
-/**
- * This class implements a DesktopManager which more closely follows
- * the MDI model than the DefaultDesktopManager.  Unlike the
- * DefaultDesktopManager policy, MDI requires that the selected
- * and activated child frames are the same, and that that frame
- * always be the top-most window.
- * <p>
- * The maximized state is managed by the DesktopManager with MDI,
- * instead of just being a property of the individual child frame.
- * This means that if the currently selected window is maximized
- * and another window is selected, that new window will be maximized.
- *
- * @see javax.swing.DefaultDesktopManager
- * @author Thomas Ball
- */
-@SuppressWarnings("serial") // JDK-implementation class
-public class WindowsDesktopManager extends DefaultDesktopManager
-        implements java.io.Serializable, javax.swing.plaf.UIResource {
-
-    /* The frame which is currently selected/activated.
-     * We store this value to enforce MDI's single-selection model.
-     */
-    private WeakReference<JInternalFrame> currentFrameRef;
-
-    public void activateFrame(JInternalFrame f) {
-        JInternalFrame currentFrame = currentFrameRef != null ?
-            currentFrameRef.get() : null;
-        try {
-            super.activateFrame(f);
-            if (currentFrame != null && f != currentFrame) {
-                // If the current frame is maximized, transfer that
-                // attribute to the frame being activated.
-                if (!currentFrame.isClosed() && currentFrame.isMaximum() &&
-                    (f.getClientProperty("JInternalFrame.frameType") !=
-                    "optionDialog") ) {
-                    //Special case.  If key binding was used to select next
-                    //frame instead of minimizing the icon via the minimize
-                    //icon.
-                    if (!currentFrame.isIcon()) {
-                        currentFrame.setMaximum(false);
-                        if (f.isMaximizable()) {
-                            if (!f.isMaximum()) {
-                                f.setMaximum(true);
-                            } else if (f.isMaximum() && f.isIcon()) {
-                                f.setIcon(false);
-                            } else {
-                                f.setMaximum(false);
-                            }
-                        }
-                    }
-                }
-                if (currentFrame.isSelected()) {
-                    currentFrame.setSelected(false);
-                }
-            }
-
-            if (!f.isSelected()) {
-                f.setSelected(true);
-            }
-        } catch (PropertyVetoException e) {}
-        if (f != currentFrame) {
-            currentFrameRef = new WeakReference<JInternalFrame>(f);
-        }
-    }
-
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsDesktopPaneUI.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,72 +0,0 @@
-/*
- * Copyright (c) 1997, 2014, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import javax.swing.*;
-import javax.swing.plaf.basic.*;
-import javax.swing.plaf.ComponentUI;
-import java.awt.event.*;
-
-/**
- * Windows desktop pane.
- * <p>
- * <strong>Warning:</strong>
- * Serialized objects of this class will not be compatible with
- * future Swing releases.  The current serialization support is appropriate
- * for short term storage or RMI between applications running the same
- * version of Swing.  A future release of Swing will provide support for
- * long term persistence.
- *
- * @author David Kloba
- */
-public class WindowsDesktopPaneUI extends BasicDesktopPaneUI
-{
-    public static ComponentUI createUI(JComponent c) {
-        return new WindowsDesktopPaneUI();
-    }
-
-    protected void installDesktopManager() {
-        desktopManager = desktop.getDesktopManager();
-        if(desktopManager == null) {
-            desktopManager = new WindowsDesktopManager();
-            desktop.setDesktopManager(desktopManager);
-        }
-    }
-
-    protected void installDefaults() {
-        super.installDefaults();
-    }
-
-    @SuppressWarnings("deprecation")
-    protected void installKeyboardActions() {
-        super.installKeyboardActions();
-
-        // Request focus if it isn't set.
-        if(!desktop.requestDefaultFocus()) {
-            desktop.requestFocus();
-        }
-    }
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsDesktopProperty.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,64 +0,0 @@
-/*
- * Copyright (c) 2001, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import javax.swing.UIManager;
-
-import sun.swing.plaf.DesktopProperty;
-
-/**
- * Wrapper for a value from the desktop. The value is lazily looked up, and
- * can be accessed using the <code>UIManager.ActiveValue</code> method
- * <code>createValue</code>. If the underlying desktop property changes this
- * will force the UIs to update all known Frames. You can invoke
- * <code>invalidate</code> to force the value to be fetched again.
- */
-public class WindowsDesktopProperty extends DesktopProperty {
-
-    /**
-     * Updates the UIs of all the known Frames.
-     */
-    @Override
-    protected final void updateAllUIs() {
-        // Check if the current UI is WindowsLookAndfeel and flush the XP style map.
-        // Note: Change the package test if this class is moved to a different package.
-        Class<?> uiClass = UIManager.getLookAndFeel().getClass();
-        if (uiClass.getPackage().equals(WindowsDesktopProperty.class.getPackage())) {
-            XPStyle.invalidateStyle();
-        }
-        super.updateAllUIs();
-    }
-
-    /**
-     * Creates a WindowsDesktopProperty.
-     *
-     * @param key Key used in looking up desktop value.
-     * @param fallback Value used if desktop property is null.
-     */
-    public WindowsDesktopProperty(String key, Object fallback) {
-        super(key,fallback);
-    }
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsEditorPaneUI.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,68 +0,0 @@
-/*
- * Copyright (c) 1997, 1998, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import javax.swing.plaf.*;
-import javax.swing.plaf.basic.*;
-import javax.swing.*;
-import javax.swing.text.Caret;
-
-
-/**
- * Windows rendition of the component.
- * <p>
- * <strong>Warning:</strong>
- * Serialized objects of this class will not be compatible with
- * future Swing releases.  The current serialization support is appropriate
- * for short term storage or RMI between applications running the same
- * version of Swing.  A future release of Swing will provide support for
- * long term persistence.
- */
-public class WindowsEditorPaneUI extends BasicEditorPaneUI
-{
-
-    /**
-     * Creates a UI for a JEditorPane.
-     *
-     * @param c the configurable text component
-     * @return the UI
-     */
-    public static ComponentUI createUI(JComponent c) {
-        return new WindowsEditorPaneUI();
-    }
-
-    /**
-     * Creates the object to use for a caret.  By default an
-     * instance of WindowsCaret is created.  This method
-     * can be redefined to provide something else that implements
-     * the InputPosition interface or a subclass of DefaultCaret.
-     *
-     * @return the caret object
-     */
-    protected Caret createCaret() {
-        return new WindowsTextUI.WindowsCaret();
-    }
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsFileChooserUI.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,1325 +0,0 @@
-/*
- * Copyright (c) 1997, 2014, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import javax.swing.*;
-import javax.swing.border.*;
-import javax.swing.filechooser.*;
-import javax.swing.event.*;
-import javax.swing.plaf.*;
-import javax.swing.plaf.basic.*;
-import java.awt.*;
-import java.awt.event.*;
-import java.awt.image.BufferedImage;
-import java.beans.*;
-import java.io.File;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.util.*;
-import java.security.AccessController;
-import java.security.PrivilegedAction;
-
-import sun.awt.shell.ShellFolder;
-import sun.swing.*;
-
-import javax.accessibility.*;
-
-/**
- * Windows {@literal L&F} implementation of a FileChooser.
- *
- * @author Jeff Dinkins
- */
-public class WindowsFileChooserUI extends BasicFileChooserUI {
-
-    // The following are private because the implementation of the
-    // Windows FileChooser L&F is not complete yet.
-
-    private JPanel centerPanel;
-
-    private JLabel lookInLabel;
-    private JComboBox<File> directoryComboBox;
-    private DirectoryComboBoxModel directoryComboBoxModel;
-    private ActionListener directoryComboBoxAction = new DirectoryComboBoxAction();
-
-    private FilterComboBoxModel filterComboBoxModel;
-
-    private JTextField filenameTextField;
-    private FilePane filePane;
-    private WindowsPlacesBar placesBar;
-
-    private JButton approveButton;
-    private JButton cancelButton;
-
-    private JPanel buttonPanel;
-    private JPanel bottomPanel;
-
-    private JComboBox<FileFilter> filterComboBox;
-
-    private static final Dimension hstrut10 = new Dimension(10, 1);
-
-    private static final Dimension vstrut4  = new Dimension(1, 4);
-    private static final Dimension vstrut6  = new Dimension(1, 6);
-    private static final Dimension vstrut8  = new Dimension(1, 8);
-
-    private static final Insets shrinkwrap = new Insets(0,0,0,0);
-
-    // Preferred and Minimum sizes for the dialog box
-    private static int PREF_WIDTH = 425;
-    private static int PREF_HEIGHT = 245;
-    private static Dimension PREF_SIZE = new Dimension(PREF_WIDTH, PREF_HEIGHT);
-
-    private static int MIN_WIDTH = 425;
-    private static int MIN_HEIGHT = 245;
-
-    private static int LIST_PREF_WIDTH = 444;
-    private static int LIST_PREF_HEIGHT = 138;
-    private static Dimension LIST_PREF_SIZE = new Dimension(LIST_PREF_WIDTH, LIST_PREF_HEIGHT);
-
-    // Labels, mnemonics, and tooltips (oh my!)
-    private int    lookInLabelMnemonic = 0;
-    private String lookInLabelText = null;
-    private String saveInLabelText = null;
-
-    private int    fileNameLabelMnemonic = 0;
-    private String fileNameLabelText = null;
-    private int    folderNameLabelMnemonic = 0;
-    private String folderNameLabelText = null;
-
-    private int    filesOfTypeLabelMnemonic = 0;
-    private String filesOfTypeLabelText = null;
-
-    private String upFolderToolTipText = null;
-    private String upFolderAccessibleName = null;
-
-    private String newFolderToolTipText = null;
-    private String newFolderAccessibleName = null;
-
-    private String viewMenuButtonToolTipText = null;
-    private String viewMenuButtonAccessibleName = null;
-
-    private BasicFileView fileView = new WindowsFileView();
-
-    private JLabel fileNameLabel;
-
-    private void populateFileNameLabel() {
-        if (getFileChooser().getFileSelectionMode() == JFileChooser.DIRECTORIES_ONLY) {
-            fileNameLabel.setText(folderNameLabelText);
-            fileNameLabel.setDisplayedMnemonic(folderNameLabelMnemonic);
-        } else {
-            fileNameLabel.setText(fileNameLabelText);
-            fileNameLabel.setDisplayedMnemonic(fileNameLabelMnemonic);
-        }
-    }
-
-    //
-    // ComponentUI Interface Implementation methods
-    //
-    public static ComponentUI createUI(JComponent c) {
-        return new WindowsFileChooserUI((JFileChooser) c);
-    }
-
-    public WindowsFileChooserUI(JFileChooser filechooser) {
-        super(filechooser);
-    }
-
-    public void installUI(JComponent c) {
-        super.installUI(c);
-    }
-
-    public void uninstallComponents(JFileChooser fc) {
-        fc.removeAll();
-    }
-
-    private class WindowsFileChooserUIAccessor implements FilePane.FileChooserUIAccessor {
-        public JFileChooser getFileChooser() {
-            return WindowsFileChooserUI.this.getFileChooser();
-        }
-
-        public BasicDirectoryModel getModel() {
-            return WindowsFileChooserUI.this.getModel();
-        }
-
-        public JPanel createList() {
-            return WindowsFileChooserUI.this.createList(getFileChooser());
-        }
-
-        public JPanel createDetailsView() {
-            return WindowsFileChooserUI.this.createDetailsView(getFileChooser());
-        }
-
-        public boolean isDirectorySelected() {
-            return WindowsFileChooserUI.this.isDirectorySelected();
-        }
-
-        public File getDirectory() {
-            return WindowsFileChooserUI.this.getDirectory();
-        }
-
-        public Action getChangeToParentDirectoryAction() {
-            return WindowsFileChooserUI.this.getChangeToParentDirectoryAction();
-        }
-
-        public Action getApproveSelectionAction() {
-            return WindowsFileChooserUI.this.getApproveSelectionAction();
-        }
-
-        public Action getNewFolderAction() {
-            return WindowsFileChooserUI.this.getNewFolderAction();
-        }
-
-        public MouseListener createDoubleClickListener(JList<?> list) {
-            return WindowsFileChooserUI.this.createDoubleClickListener(getFileChooser(),
-                                                                       list);
-        }
-
-        public ListSelectionListener createListSelectionListener() {
-            return WindowsFileChooserUI.this.createListSelectionListener(getFileChooser());
-        }
-    }
-
-    public void installComponents(JFileChooser fc) {
-        filePane = new FilePane(new WindowsFileChooserUIAccessor());
-        fc.addPropertyChangeListener(filePane);
-
-        FileSystemView fsv = fc.getFileSystemView();
-
-        fc.setBorder(new EmptyBorder(4, 10, 10, 10));
-        fc.setLayout(new BorderLayout(8, 8));
-
-        updateUseShellFolder();
-
-        // ********************************* //
-        // **** Construct the top panel **** //
-        // ********************************* //
-
-        // Directory manipulation buttons
-        JToolBar topPanel = new JToolBar();
-        topPanel.setFloatable(false);
-        topPanel.putClientProperty("JToolBar.isRollover", Boolean.TRUE);
-
-        // Add the top panel to the fileChooser
-        fc.add(topPanel, BorderLayout.NORTH);
-
-        // ComboBox Label
-        @SuppressWarnings("serial") // anonymous class
-        JLabel tmp1 = new JLabel(lookInLabelText, JLabel.TRAILING) {
-            public Dimension getPreferredSize() {
-                return getMinimumSize();
-            }
-
-            public Dimension getMinimumSize() {
-                Dimension d = super.getPreferredSize();
-                if (placesBar != null) {
-                    d.width = Math.max(d.width, placesBar.getWidth());
-                }
-                return d;
-            }
-        };
-        lookInLabel = tmp1;
-        lookInLabel.setDisplayedMnemonic(lookInLabelMnemonic);
-        lookInLabel.setAlignmentX(JComponent.LEFT_ALIGNMENT);
-        lookInLabel.setAlignmentY(JComponent.CENTER_ALIGNMENT);
-        topPanel.add(lookInLabel);
-        topPanel.add(Box.createRigidArea(new Dimension(8,0)));
-
-        // CurrentDir ComboBox
-        @SuppressWarnings("serial") // anonymous class
-        JComboBox<File> tmp2 = new JComboBox<File>() {
-            public Dimension getMinimumSize() {
-                Dimension d = super.getMinimumSize();
-                d.width = 60;
-                return d;
-            }
-
-            public Dimension getPreferredSize() {
-                Dimension d = super.getPreferredSize();
-                // Must be small enough to not affect total width.
-                d.width = 150;
-                return d;
-            }
-        };
-        directoryComboBox = tmp2;
-        directoryComboBox.putClientProperty( "JComboBox.lightweightKeyboardNavigation", "Lightweight" );
-        lookInLabel.setLabelFor(directoryComboBox);
-        directoryComboBoxModel = createDirectoryComboBoxModel(fc);
-        directoryComboBox.setModel(directoryComboBoxModel);
-        directoryComboBox.addActionListener(directoryComboBoxAction);
-        directoryComboBox.setRenderer(createDirectoryComboBoxRenderer(fc));
-        directoryComboBox.setAlignmentX(JComponent.LEFT_ALIGNMENT);
-        directoryComboBox.setAlignmentY(JComponent.CENTER_ALIGNMENT);
-        directoryComboBox.setMaximumRowCount(8);
-
-        topPanel.add(directoryComboBox);
-        topPanel.add(Box.createRigidArea(hstrut10));
-
-        // Up Button
-        JButton upFolderButton = createToolButton(getChangeToParentDirectoryAction(), upFolderIcon,
-            upFolderToolTipText, upFolderAccessibleName);
-        topPanel.add(upFolderButton);
-
-        // New Directory Button
-        if (!UIManager.getBoolean("FileChooser.readOnly")) {
-            JButton newFolderButton = createToolButton(filePane.getNewFolderAction(), newFolderIcon,
-                newFolderToolTipText, newFolderAccessibleName);
-            topPanel.add(newFolderButton);
-        }
-
-        // View button group
-        ButtonGroup viewButtonGroup = new ButtonGroup();
-
-        // Popup Menu
-        final JPopupMenu viewTypePopupMenu = new JPopupMenu();
-
-        final JRadioButtonMenuItem listViewMenuItem = new JRadioButtonMenuItem(
-                filePane.getViewTypeAction(FilePane.VIEWTYPE_LIST));
-        listViewMenuItem.setSelected(filePane.getViewType() == FilePane.VIEWTYPE_LIST);
-        viewTypePopupMenu.add(listViewMenuItem);
-        viewButtonGroup.add(listViewMenuItem);
-
-        final JRadioButtonMenuItem detailsViewMenuItem = new JRadioButtonMenuItem(
-                filePane.getViewTypeAction(FilePane.VIEWTYPE_DETAILS));
-        detailsViewMenuItem.setSelected(filePane.getViewType() == FilePane.VIEWTYPE_DETAILS);
-        viewTypePopupMenu.add(detailsViewMenuItem);
-        viewButtonGroup.add(detailsViewMenuItem);
-
-        // Create icon for viewMenuButton
-        BufferedImage image = new BufferedImage(viewMenuIcon.getIconWidth() + 7, viewMenuIcon.getIconHeight(),
-                BufferedImage.TYPE_INT_ARGB);
-        Graphics graphics = image.getGraphics();
-        viewMenuIcon.paintIcon(filePane, graphics, 0, 0);
-        int x = image.getWidth() - 5;
-        int y = image.getHeight() / 2 - 1;
-        graphics.setColor(Color.BLACK);
-        graphics.fillPolygon(new int[]{x, x + 5, x + 2}, new int[]{y, y, y + 3}, 3);
-
-        // Details Button
-        final JButton viewMenuButton = createToolButton(null, new ImageIcon(image), viewMenuButtonToolTipText,
-                viewMenuButtonAccessibleName);
-
-        viewMenuButton.addMouseListener(new MouseAdapter() {
-            public void mousePressed(MouseEvent e) {
-                if (SwingUtilities.isLeftMouseButton(e) && !viewMenuButton.isSelected()) {
-                    viewMenuButton.setSelected(true);
-
-                    viewTypePopupMenu.show(viewMenuButton, 0, viewMenuButton.getHeight());
-                }
-            }
-        });
-        viewMenuButton.addKeyListener(new KeyAdapter() {
-            public void keyPressed(KeyEvent e) {
-                // Forbid keyboard actions if the button is not in rollover state
-                if (e.getKeyCode() == KeyEvent.VK_SPACE && viewMenuButton.getModel().isRollover()) {
-                    viewMenuButton.setSelected(true);
-
-                    viewTypePopupMenu.show(viewMenuButton, 0, viewMenuButton.getHeight());
-                }
-            }
-        });
-        viewTypePopupMenu.addPopupMenuListener(new PopupMenuListener() {
-            public void popupMenuWillBecomeVisible(PopupMenuEvent e) {
-            }
-
-            public void popupMenuWillBecomeInvisible(PopupMenuEvent e) {
-                SwingUtilities.invokeLater(new Runnable() {
-                    public void run() {
-                        viewMenuButton.setSelected(false);
-                    }
-                });
-            }
-
-            public void popupMenuCanceled(PopupMenuEvent e) {
-            }
-        });
-
-        topPanel.add(viewMenuButton);
-
-        topPanel.add(Box.createRigidArea(new Dimension(80, 0)));
-
-        filePane.addPropertyChangeListener(new PropertyChangeListener() {
-            public void propertyChange(PropertyChangeEvent e) {
-                if ("viewType".equals(e.getPropertyName())) {
-                    switch (filePane.getViewType()) {
-                        case FilePane.VIEWTYPE_LIST:
-                            listViewMenuItem.setSelected(true);
-                            break;
-
-                        case FilePane.VIEWTYPE_DETAILS:
-                            detailsViewMenuItem.setSelected(true);
-                            break;
-                    }
-                }
-            }
-        });
-
-        // ************************************** //
-        // ******* Add the directory pane ******* //
-        // ************************************** //
-        centerPanel = new JPanel(new BorderLayout());
-        centerPanel.add(getAccessoryPanel(), BorderLayout.AFTER_LINE_ENDS);
-        JComponent accessory = fc.getAccessory();
-        if(accessory != null) {
-            getAccessoryPanel().add(accessory);
-        }
-        filePane.setPreferredSize(LIST_PREF_SIZE);
-        centerPanel.add(filePane, BorderLayout.CENTER);
-        fc.add(centerPanel, BorderLayout.CENTER);
-
-        // ********************************** //
-        // **** Construct the bottom panel ** //
-        // ********************************** //
-        getBottomPanel().setLayout(new BoxLayout(getBottomPanel(), BoxLayout.LINE_AXIS));
-
-        // Add the bottom panel to file chooser
-        centerPanel.add(getBottomPanel(), BorderLayout.SOUTH);
-
-        // labels
-        JPanel labelPanel = new JPanel();
-        labelPanel.setLayout(new BoxLayout(labelPanel, BoxLayout.PAGE_AXIS));
-        labelPanel.add(Box.createRigidArea(vstrut4));
-
-        fileNameLabel = new JLabel();
-        populateFileNameLabel();
-        fileNameLabel.setAlignmentY(0);
-        labelPanel.add(fileNameLabel);
-
-        labelPanel.add(Box.createRigidArea(new Dimension(1,12)));
-
-        JLabel ftl = new JLabel(filesOfTypeLabelText);
-        ftl.setDisplayedMnemonic(filesOfTypeLabelMnemonic);
-        labelPanel.add(ftl);
-
-        getBottomPanel().add(labelPanel);
-        getBottomPanel().add(Box.createRigidArea(new Dimension(15, 0)));
-
-        // file entry and filters
-        JPanel fileAndFilterPanel = new JPanel();
-        fileAndFilterPanel.add(Box.createRigidArea(vstrut8));
-        fileAndFilterPanel.setLayout(new BoxLayout(fileAndFilterPanel, BoxLayout.Y_AXIS));
-
-        @SuppressWarnings("serial") // anonymous class
-        JTextField tmp3 = new JTextField(35) {
-            public Dimension getMaximumSize() {
-                return new Dimension(Short.MAX_VALUE, super.getPreferredSize().height);
-            }
-        };
-        filenameTextField = tmp3;
-
-        fileNameLabel.setLabelFor(filenameTextField);
-        filenameTextField.addFocusListener(
-            new FocusAdapter() {
-                public void focusGained(FocusEvent e) {
-                    if (!getFileChooser().isMultiSelectionEnabled()) {
-                        filePane.clearSelection();
-                    }
-                }
-            }
-        );
-
-        if (fc.isMultiSelectionEnabled()) {
-            setFileName(fileNameString(fc.getSelectedFiles()));
-        } else {
-            setFileName(fileNameString(fc.getSelectedFile()));
-        }
-
-        fileAndFilterPanel.add(filenameTextField);
-        fileAndFilterPanel.add(Box.createRigidArea(vstrut8));
-
-        filterComboBoxModel = createFilterComboBoxModel();
-        fc.addPropertyChangeListener(filterComboBoxModel);
-        filterComboBox = new JComboBox<FileFilter>(filterComboBoxModel);
-        ftl.setLabelFor(filterComboBox);
-        filterComboBox.setRenderer(createFilterComboBoxRenderer());
-        fileAndFilterPanel.add(filterComboBox);
-
-        getBottomPanel().add(fileAndFilterPanel);
-        getBottomPanel().add(Box.createRigidArea(new Dimension(30, 0)));
-
-        // buttons
-        getButtonPanel().setLayout(new BoxLayout(getButtonPanel(), BoxLayout.Y_AXIS));
-
-        @SuppressWarnings("serial") // anonymous class
-        JButton tmp4 = new JButton(getApproveButtonText(fc)) {
-            public Dimension getMaximumSize() {
-                return approveButton.getPreferredSize().width > cancelButton.getPreferredSize().width ?
-                       approveButton.getPreferredSize() : cancelButton.getPreferredSize();
-            }
-        };
-        approveButton = tmp4;
-        Insets buttonMargin = approveButton.getMargin();
-        buttonMargin = new InsetsUIResource(buttonMargin.top,    buttonMargin.left  + 5,
-                                            buttonMargin.bottom, buttonMargin.right + 5);
-        approveButton.setMargin(buttonMargin);
-        approveButton.setMnemonic(getApproveButtonMnemonic(fc));
-        approveButton.addActionListener(getApproveSelectionAction());
-        approveButton.setToolTipText(getApproveButtonToolTipText(fc));
-        getButtonPanel().add(Box.createRigidArea(vstrut6));
-        getButtonPanel().add(approveButton);
-        getButtonPanel().add(Box.createRigidArea(vstrut4));
-
-        @SuppressWarnings("serial") // anonymous class
-        JButton tmp5 = new JButton(cancelButtonText) {
-            public Dimension getMaximumSize() {
-                return approveButton.getPreferredSize().width > cancelButton.getPreferredSize().width ?
-                       approveButton.getPreferredSize() : cancelButton.getPreferredSize();
-            }
-        };
-        cancelButton = tmp5;
-        cancelButton.setMargin(buttonMargin);
-        cancelButton.setToolTipText(cancelButtonToolTipText);
-        cancelButton.addActionListener(getCancelSelectionAction());
-        getButtonPanel().add(cancelButton);
-
-        if(fc.getControlButtonsAreShown()) {
-            addControlButtons();
-        }
-    }
-
-    private void updateUseShellFolder() {
-        // Decide whether to use the ShellFolder class to populate shortcut
-        // panel and combobox.
-        JFileChooser fc = getFileChooser();
-
-        if (FilePane.usesShellFolder(fc)) {
-            if (placesBar == null && !UIManager.getBoolean("FileChooser.noPlacesBar")) {
-                placesBar = new WindowsPlacesBar(fc, XPStyle.getXP() != null);
-                fc.add(placesBar, BorderLayout.BEFORE_LINE_BEGINS);
-                fc.addPropertyChangeListener(placesBar);
-            }
-        } else {
-            if (placesBar != null) {
-                fc.remove(placesBar);
-                fc.removePropertyChangeListener(placesBar);
-                placesBar = null;
-            }
-        }
-    }
-
-    protected JPanel getButtonPanel() {
-        if(buttonPanel == null) {
-            buttonPanel = new JPanel();
-        }
-        return buttonPanel;
-    }
-
-    protected JPanel getBottomPanel() {
-        if(bottomPanel == null) {
-            bottomPanel = new JPanel();
-        }
-        return bottomPanel;
-    }
-
-    protected void installStrings(JFileChooser fc) {
-        super.installStrings(fc);
-
-        Locale l = fc.getLocale();
-
-        lookInLabelMnemonic = getMnemonic("FileChooser.lookInLabelMnemonic", l);
-        lookInLabelText = UIManager.getString("FileChooser.lookInLabelText",l);
-        saveInLabelText = UIManager.getString("FileChooser.saveInLabelText",l);
-
-        fileNameLabelMnemonic = getMnemonic("FileChooser.fileNameLabelMnemonic", l);
-        fileNameLabelText = UIManager.getString("FileChooser.fileNameLabelText",l);
-        folderNameLabelMnemonic = getMnemonic("FileChooser.folderNameLabelMnemonic", l);
-        folderNameLabelText = UIManager.getString("FileChooser.folderNameLabelText",l);
-
-        filesOfTypeLabelMnemonic = getMnemonic("FileChooser.filesOfTypeLabelMnemonic", l);
-        filesOfTypeLabelText = UIManager.getString("FileChooser.filesOfTypeLabelText",l);
-
-        upFolderToolTipText =  UIManager.getString("FileChooser.upFolderToolTipText",l);
-        upFolderAccessibleName = UIManager.getString("FileChooser.upFolderAccessibleName",l);
-
-        newFolderToolTipText = UIManager.getString("FileChooser.newFolderToolTipText",l);
-        newFolderAccessibleName = UIManager.getString("FileChooser.newFolderAccessibleName",l);
-
-        viewMenuButtonToolTipText = UIManager.getString("FileChooser.viewMenuButtonToolTipText",l);
-        viewMenuButtonAccessibleName = UIManager.getString("FileChooser.viewMenuButtonAccessibleName",l);
-    }
-
-    private Integer getMnemonic(String key, Locale l) {
-        return SwingUtilities2.getUIDefaultsInt(key, l);
-    }
-
-    protected void installListeners(JFileChooser fc) {
-        super.installListeners(fc);
-        ActionMap actionMap = getActionMap();
-        SwingUtilities.replaceUIActionMap(fc, actionMap);
-    }
-
-    protected ActionMap getActionMap() {
-        return createActionMap();
-    }
-
-    protected ActionMap createActionMap() {
-        ActionMap map = new ActionMapUIResource();
-        FilePane.addActionsToMap(map, filePane.getActions());
-        return map;
-    }
-
-    protected JPanel createList(JFileChooser fc) {
-        return filePane.createList();
-    }
-
-    protected JPanel createDetailsView(JFileChooser fc) {
-        return filePane.createDetailsView();
-    }
-
-    /**
-     * Creates a selection listener for the list of files and directories.
-     *
-     * @param fc a <code>JFileChooser</code>
-     * @return a <code>ListSelectionListener</code>
-     */
-    public ListSelectionListener createListSelectionListener(JFileChooser fc) {
-        return super.createListSelectionListener(fc);
-    }
-
-    // Obsolete class, not used in this version.
-    @SuppressWarnings("serial")
-    protected class WindowsNewFolderAction extends NewFolderAction {
-    }
-
-    // Obsolete class, not used in this version.
-    protected class SingleClickListener extends MouseAdapter {
-    }
-
-    // Obsolete class, not used in this version.
-    @SuppressWarnings("serial") // Superclass is not serializable across versions
-    protected class FileRenderer extends DefaultListCellRenderer  {
-    }
-
-    public void uninstallUI(JComponent c) {
-        // Remove listeners
-        c.removePropertyChangeListener(filterComboBoxModel);
-        c.removePropertyChangeListener(filePane);
-        if (placesBar != null) {
-            c.removePropertyChangeListener(placesBar);
-        }
-        cancelButton.removeActionListener(getCancelSelectionAction());
-        approveButton.removeActionListener(getApproveSelectionAction());
-        filenameTextField.removeActionListener(getApproveSelectionAction());
-
-        if (filePane != null) {
-            filePane.uninstallUI();
-            filePane = null;
-        }
-
-        super.uninstallUI(c);
-    }
-
-    /**
-     * Returns the preferred size of the specified
-     * <code>JFileChooser</code>.
-     * The preferred size is at least as large,
-     * in both height and width,
-     * as the preferred size recommended
-     * by the file chooser's layout manager.
-     *
-     * @param c  a <code>JFileChooser</code>
-     * @return   a <code>Dimension</code> specifying the preferred
-     *           width and height of the file chooser
-     */
-    @Override
-    public Dimension getPreferredSize(JComponent c) {
-        int prefWidth = PREF_SIZE.width;
-        Dimension d = c.getLayout().preferredLayoutSize(c);
-        if (d != null) {
-            return new Dimension(d.width < prefWidth ? prefWidth : d.width,
-                                 d.height < PREF_SIZE.height ? PREF_SIZE.height : d.height);
-        } else {
-            return new Dimension(prefWidth, PREF_SIZE.height);
-        }
-    }
-
-    /**
-     * Returns the minimum size of the <code>JFileChooser</code>.
-     *
-     * @param c  a <code>JFileChooser</code>
-     * @return   a <code>Dimension</code> specifying the minimum
-     *           width and height of the file chooser
-     */
-    @Override
-    public Dimension getMinimumSize(JComponent c) {
-        return new Dimension(MIN_WIDTH, MIN_HEIGHT);
-    }
-
-    /**
-     * Returns the maximum size of the <code>JFileChooser</code>.
-     *
-     * @param c  a <code>JFileChooser</code>
-     * @return   a <code>Dimension</code> specifying the maximum
-     *           width and height of the file chooser
-     */
-    @Override
-    public Dimension getMaximumSize(JComponent c) {
-        return new Dimension(Integer.MAX_VALUE, Integer.MAX_VALUE);
-    }
-
-    private String fileNameString(File file) {
-        if (file == null) {
-            return null;
-        } else {
-            JFileChooser fc = getFileChooser();
-            if ((fc.isDirectorySelectionEnabled() && !fc.isFileSelectionEnabled()) ||
-                (fc.isDirectorySelectionEnabled() && fc.isFileSelectionEnabled() && fc.getFileSystemView().isFileSystemRoot(file))){
-                return file.getPath();
-            } else {
-                return file.getName();
-            }
-        }
-    }
-
-    private String fileNameString(File[] files) {
-        StringBuilder buf = new StringBuilder();
-        for (int i = 0; files != null && i < files.length; i++) {
-            if (i > 0) {
-                buf.append(" ");
-            }
-            if (files.length > 1) {
-                buf.append("\"");
-            }
-            buf.append(fileNameString(files[i]));
-            if (files.length > 1) {
-                buf.append("\"");
-            }
-        }
-        return buf.toString();
-    }
-
-    /* The following methods are used by the PropertyChange Listener */
-
-    private void doSelectedFileChanged(PropertyChangeEvent e) {
-        File f = (File) e.getNewValue();
-        JFileChooser fc = getFileChooser();
-        if (f != null
-            && ((fc.isFileSelectionEnabled() && !f.isDirectory())
-                || (f.isDirectory() && fc.isDirectorySelectionEnabled()))) {
-
-            setFileName(fileNameString(f));
-        }
-    }
-
-    private void doSelectedFilesChanged(PropertyChangeEvent e) {
-        File[] files = (File[]) e.getNewValue();
-        JFileChooser fc = getFileChooser();
-        if (files != null
-            && files.length > 0
-            && (files.length > 1 || fc.isDirectorySelectionEnabled() || !files[0].isDirectory())) {
-            setFileName(fileNameString(files));
-        }
-    }
-
-    private void doDirectoryChanged(PropertyChangeEvent e) {
-        JFileChooser fc = getFileChooser();
-        FileSystemView fsv = fc.getFileSystemView();
-
-        clearIconCache();
-        File currentDirectory = fc.getCurrentDirectory();
-        if(currentDirectory != null) {
-            directoryComboBoxModel.addItem(currentDirectory);
-
-            if (fc.isDirectorySelectionEnabled() && !fc.isFileSelectionEnabled()) {
-                if (fsv.isFileSystem(currentDirectory)) {
-                    setFileName(currentDirectory.getPath());
-                } else {
-                    setFileName(null);
-                }
-            }
-        }
-    }
-
-    private void doFilterChanged(PropertyChangeEvent e) {
-        clearIconCache();
-    }
-
-    private void doFileSelectionModeChanged(PropertyChangeEvent e) {
-        if (fileNameLabel != null) {
-            populateFileNameLabel();
-        }
-        clearIconCache();
-
-        JFileChooser fc = getFileChooser();
-        File currentDirectory = fc.getCurrentDirectory();
-        if (currentDirectory != null
-            && fc.isDirectorySelectionEnabled()
-            && !fc.isFileSelectionEnabled()
-            && fc.getFileSystemView().isFileSystem(currentDirectory)) {
-
-            setFileName(currentDirectory.getPath());
-        } else {
-            setFileName(null);
-        }
-    }
-
-    private void doAccessoryChanged(PropertyChangeEvent e) {
-        if(getAccessoryPanel() != null) {
-            if(e.getOldValue() != null) {
-                getAccessoryPanel().remove((JComponent) e.getOldValue());
-            }
-            JComponent accessory = (JComponent) e.getNewValue();
-            if(accessory != null) {
-                getAccessoryPanel().add(accessory, BorderLayout.CENTER);
-            }
-        }
-    }
-
-    private void doApproveButtonTextChanged(PropertyChangeEvent e) {
-        JFileChooser chooser = getFileChooser();
-        approveButton.setText(getApproveButtonText(chooser));
-        approveButton.setToolTipText(getApproveButtonToolTipText(chooser));
-        approveButton.setMnemonic(getApproveButtonMnemonic(chooser));
-    }
-
-    private void doDialogTypeChanged(PropertyChangeEvent e) {
-        JFileChooser chooser = getFileChooser();
-        approveButton.setText(getApproveButtonText(chooser));
-        approveButton.setToolTipText(getApproveButtonToolTipText(chooser));
-        approveButton.setMnemonic(getApproveButtonMnemonic(chooser));
-        if (chooser.getDialogType() == JFileChooser.SAVE_DIALOG) {
-            lookInLabel.setText(saveInLabelText);
-        } else {
-            lookInLabel.setText(lookInLabelText);
-        }
-    }
-
-    private void doApproveButtonMnemonicChanged(PropertyChangeEvent e) {
-        approveButton.setMnemonic(getApproveButtonMnemonic(getFileChooser()));
-    }
-
-    private void doControlButtonsChanged(PropertyChangeEvent e) {
-        if(getFileChooser().getControlButtonsAreShown()) {
-            addControlButtons();
-        } else {
-            removeControlButtons();
-        }
-    }
-
-    /*
-     * Listen for filechooser property changes, such as
-     * the selected file changing, or the type of the dialog changing.
-     */
-    public PropertyChangeListener createPropertyChangeListener(JFileChooser fc) {
-        return new PropertyChangeListener() {
-            public void propertyChange(PropertyChangeEvent e) {
-                String s = e.getPropertyName();
-                if(s.equals(JFileChooser.SELECTED_FILE_CHANGED_PROPERTY)) {
-                    doSelectedFileChanged(e);
-                } else if (s.equals(JFileChooser.SELECTED_FILES_CHANGED_PROPERTY)) {
-                    doSelectedFilesChanged(e);
-                } else if(s.equals(JFileChooser.DIRECTORY_CHANGED_PROPERTY)) {
-                    doDirectoryChanged(e);
-                } else if(s.equals(JFileChooser.FILE_FILTER_CHANGED_PROPERTY)) {
-                    doFilterChanged(e);
-                } else if(s.equals(JFileChooser.FILE_SELECTION_MODE_CHANGED_PROPERTY)) {
-                    doFileSelectionModeChanged(e);
-                } else if(s.equals(JFileChooser.ACCESSORY_CHANGED_PROPERTY)) {
-                    doAccessoryChanged(e);
-                } else if (s.equals(JFileChooser.APPROVE_BUTTON_TEXT_CHANGED_PROPERTY) ||
-                           s.equals(JFileChooser.APPROVE_BUTTON_TOOL_TIP_TEXT_CHANGED_PROPERTY)) {
-                    doApproveButtonTextChanged(e);
-                } else if(s.equals(JFileChooser.DIALOG_TYPE_CHANGED_PROPERTY)) {
-                    doDialogTypeChanged(e);
-                } else if(s.equals(JFileChooser.APPROVE_BUTTON_MNEMONIC_CHANGED_PROPERTY)) {
-                    doApproveButtonMnemonicChanged(e);
-                } else if(s.equals(JFileChooser.CONTROL_BUTTONS_ARE_SHOWN_CHANGED_PROPERTY)) {
-                    doControlButtonsChanged(e);
-                } else if (s == "FileChooser.useShellFolder") {
-                    updateUseShellFolder();
-                    doDirectoryChanged(e);
-                } else if (s.equals("componentOrientation")) {
-                    ComponentOrientation o = (ComponentOrientation)e.getNewValue();
-                    JFileChooser cc = (JFileChooser)e.getSource();
-                    if (o != e.getOldValue()) {
-                        cc.applyComponentOrientation(o);
-                    }
-                } else if (s.equals("ancestor")) {
-                    if (e.getOldValue() == null && e.getNewValue() != null) {
-                        // Ancestor was added, set initial focus
-                        filenameTextField.selectAll();
-                        filenameTextField.requestFocus();
-                    }
-                }
-            }
-        };
-    }
-
-
-    protected void removeControlButtons() {
-        getBottomPanel().remove(getButtonPanel());
-    }
-
-    protected void addControlButtons() {
-        getBottomPanel().add(getButtonPanel());
-    }
-
-    public void ensureFileIsVisible(JFileChooser fc, File f) {
-        filePane.ensureFileIsVisible(fc, f);
-    }
-
-    public void rescanCurrentDirectory(JFileChooser fc) {
-        filePane.rescanCurrentDirectory();
-    }
-
-    public String getFileName() {
-        if(filenameTextField != null) {
-            return filenameTextField.getText();
-        } else {
-            return null;
-        }
-    }
-
-    public void setFileName(String filename) {
-        if(filenameTextField != null) {
-            filenameTextField.setText(filename);
-        }
-    }
-
-    /**
-     * Property to remember whether a directory is currently selected in the UI.
-     * This is normally called by the UI on a selection event.
-     *
-     * @param directorySelected if a directory is currently selected.
-     * @since 1.4
-     */
-    protected void setDirectorySelected(boolean directorySelected) {
-        super.setDirectorySelected(directorySelected);
-        JFileChooser chooser = getFileChooser();
-        if(directorySelected) {
-            approveButton.setText(directoryOpenButtonText);
-            approveButton.setToolTipText(directoryOpenButtonToolTipText);
-            approveButton.setMnemonic(directoryOpenButtonMnemonic);
-        } else {
-            approveButton.setText(getApproveButtonText(chooser));
-            approveButton.setToolTipText(getApproveButtonToolTipText(chooser));
-            approveButton.setMnemonic(getApproveButtonMnemonic(chooser));
-        }
-    }
-
-    public String getDirectoryName() {
-        // PENDING(jeff) - get the name from the directory combobox
-        return null;
-    }
-
-    public void setDirectoryName(String dirname) {
-        // PENDING(jeff) - set the name in the directory combobox
-    }
-
-    protected DirectoryComboBoxRenderer createDirectoryComboBoxRenderer(JFileChooser fc) {
-        return new DirectoryComboBoxRenderer();
-    }
-
-    @SuppressWarnings("serial") // anonymous class
-    private static JButton createToolButton(Action a, Icon defaultIcon, String toolTipText, String accessibleName) {
-        final JButton result = new JButton(a);
-
-        result.setText(null);
-        result.setIcon(defaultIcon);
-        result.setToolTipText(toolTipText);
-        result.setRequestFocusEnabled(false);
-        result.putClientProperty(AccessibleContext.ACCESSIBLE_NAME_PROPERTY, accessibleName);
-        result.putClientProperty(WindowsLookAndFeel.HI_RES_DISABLED_ICON_CLIENT_KEY, Boolean.TRUE);
-        result.setAlignmentX(JComponent.LEFT_ALIGNMENT);
-        result.setAlignmentY(JComponent.CENTER_ALIGNMENT);
-        result.setMargin(shrinkwrap);
-        result.setFocusPainted(false);
-
-        result.setModel(new DefaultButtonModel() {
-            public void setPressed(boolean b) {
-                // Forbid keyboard actions if the button is not in rollover state
-                if (!b || isRollover()) {
-                    super.setPressed(b);
-                }
-            }
-
-            public void setRollover(boolean b) {
-                if (b && !isRollover()) {
-                    // Reset other buttons
-                    for (Component component : result.getParent().getComponents()) {
-                        if (component instanceof JButton && component != result) {
-                            ((JButton) component).getModel().setRollover(false);
-                        }
-                    }
-                }
-
-                super.setRollover(b);
-            }
-
-            public void setSelected(boolean b) {
-                super.setSelected(b);
-
-                if (b) {
-                    stateMask |= PRESSED | ARMED;
-                } else {
-                    stateMask &= ~(PRESSED | ARMED);
-                }
-            }
-        });
-
-        result.addFocusListener(new FocusAdapter() {
-            public void focusGained(FocusEvent e) {
-                result.getModel().setRollover(true);
-            }
-
-            public void focusLost(FocusEvent e) {
-                result.getModel().setRollover(false);
-            }
-        });
-
-        return result;
-    }
-
-    //
-    // Renderer for DirectoryComboBox
-    //
-    @SuppressWarnings("serial") // Superclass is not serializable across versions
-    class DirectoryComboBoxRenderer extends DefaultListCellRenderer  {
-        IndentIcon ii = new IndentIcon();
-        public Component getListCellRendererComponent(JList<?> list, Object value,
-                                                      int index, boolean isSelected,
-                                                      boolean cellHasFocus) {
-
-            super.getListCellRendererComponent(list, value, index, isSelected, cellHasFocus);
-
-            if (value == null) {
-                setText("");
-                return this;
-            }
-            File directory = (File)value;
-            setText(getFileChooser().getName(directory));
-            Icon icon = getFileChooser().getIcon(directory);
-            ii.icon = icon;
-            ii.depth = directoryComboBoxModel.getDepth(index);
-            setIcon(ii);
-
-            return this;
-        }
-    }
-
-    static final int space = 10;
-    class IndentIcon implements Icon {
-
-        Icon icon = null;
-        int depth = 0;
-
-        public void paintIcon(Component c, Graphics g, int x, int y) {
-            if (c.getComponentOrientation().isLeftToRight()) {
-                icon.paintIcon(c, g, x+depth*space, y);
-            } else {
-                icon.paintIcon(c, g, x, y);
-            }
-        }
-
-        public int getIconWidth() {
-            return icon.getIconWidth() + depth*space;
-        }
-
-        public int getIconHeight() {
-            return icon.getIconHeight();
-        }
-
-    }
-
-    //
-    // DataModel for DirectoryComboxbox
-    //
-    protected DirectoryComboBoxModel createDirectoryComboBoxModel(JFileChooser fc) {
-        return new DirectoryComboBoxModel();
-    }
-
-    /**
-     * Data model for a type-face selection combo-box.
-     */
-    @SuppressWarnings("serial") // Superclass is not serializable across versions
-    protected class DirectoryComboBoxModel extends AbstractListModel<File> implements ComboBoxModel<File> {
-        Vector<File> directories = new Vector<File>();
-        int[] depths = null;
-        File selectedDirectory = null;
-        JFileChooser chooser = getFileChooser();
-        FileSystemView fsv = chooser.getFileSystemView();
-
-        public DirectoryComboBoxModel() {
-            // Add the current directory to the model, and make it the
-            // selectedDirectory
-            File dir = getFileChooser().getCurrentDirectory();
-            if(dir != null) {
-                addItem(dir);
-            }
-        }
-
-        /**
-         * Adds the directory to the model and sets it to be selected,
-         * additionally clears out the previous selected directory and
-         * the paths leading up to it, if any.
-         */
-        private void addItem(File directory) {
-
-            if(directory == null) {
-                return;
-            }
-
-            boolean useShellFolder = FilePane.usesShellFolder(chooser);
-
-            directories.clear();
-
-            File[] baseFolders = (useShellFolder)
-                    ? (File[]) ShellFolder.get("fileChooserComboBoxFolders")
-                    : fsv.getRoots();
-            directories.addAll(Arrays.asList(baseFolders));
-
-            // Get the canonical (full) path. This has the side
-            // benefit of removing extraneous chars from the path,
-            // for example /foo/bar/ becomes /foo/bar
-            File canonical;
-            try {
-                canonical = directory.getCanonicalFile();
-            } catch (IOException e) {
-                // Maybe drive is not ready. Can't abort here.
-                canonical = directory;
-            }
-
-            // create File instances of each directory leading up to the top
-            try {
-                File sf = useShellFolder ? ShellFolder.getShellFolder(canonical)
-                                         : canonical;
-                File f = sf;
-                Vector<File> path = new Vector<File>(10);
-                do {
-                    path.addElement(f);
-                } while ((f = f.getParentFile()) != null);
-
-                int pathCount = path.size();
-                // Insert chain at appropriate place in vector
-                for (int i = 0; i < pathCount; i++) {
-                    f = path.get(i);
-                    if (directories.contains(f)) {
-                        int topIndex = directories.indexOf(f);
-                        for (int j = i-1; j >= 0; j--) {
-                            directories.insertElementAt(path.get(j), topIndex+i-j);
-                        }
-                        break;
-                    }
-                }
-                calculateDepths();
-                setSelectedItem(sf);
-            } catch (FileNotFoundException ex) {
-                calculateDepths();
-            }
-        }
-
-        private void calculateDepths() {
-            depths = new int[directories.size()];
-            for (int i = 0; i < depths.length; i++) {
-                File dir = directories.get(i);
-                File parent = dir.getParentFile();
-                depths[i] = 0;
-                if (parent != null) {
-                    for (int j = i-1; j >= 0; j--) {
-                        if (parent.equals(directories.get(j))) {
-                            depths[i] = depths[j] + 1;
-                            break;
-                        }
-                    }
-                }
-            }
-        }
-
-        public int getDepth(int i) {
-            return (depths != null && i >= 0 && i < depths.length) ? depths[i] : 0;
-        }
-
-        public void setSelectedItem(Object selectedDirectory) {
-            this.selectedDirectory = (File)selectedDirectory;
-            fireContentsChanged(this, -1, -1);
-        }
-
-        public Object getSelectedItem() {
-            return selectedDirectory;
-        }
-
-        public int getSize() {
-            return directories.size();
-        }
-
-        public File getElementAt(int index) {
-            return directories.elementAt(index);
-        }
-    }
-
-    //
-    // Renderer for Types ComboBox
-    //
-    protected FilterComboBoxRenderer createFilterComboBoxRenderer() {
-        return new FilterComboBoxRenderer();
-    }
-
-    /**
-     * Render different type sizes and styles.
-     */
-    @SuppressWarnings("serial") // Superclass is not serializable across versions
-    public class FilterComboBoxRenderer extends DefaultListCellRenderer {
-        public Component getListCellRendererComponent(JList<?> list,
-            Object value, int index, boolean isSelected,
-            boolean cellHasFocus) {
-
-            super.getListCellRendererComponent(list, value, index, isSelected, cellHasFocus);
-
-            if (value != null && value instanceof FileFilter) {
-                setText(((FileFilter)value).getDescription());
-            }
-
-            return this;
-        }
-    }
-
-    //
-    // DataModel for Types Comboxbox
-    //
-    protected FilterComboBoxModel createFilterComboBoxModel() {
-        return new FilterComboBoxModel();
-    }
-
-    /**
-     * Data model for a type-face selection combo-box.
-     */
-    @SuppressWarnings("serial") // Superclass is not serializable across versions
-    protected class FilterComboBoxModel extends AbstractListModel<FileFilter> implements ComboBoxModel<FileFilter>,
-            PropertyChangeListener {
-        protected FileFilter[] filters;
-        protected FilterComboBoxModel() {
-            super();
-            filters = getFileChooser().getChoosableFileFilters();
-        }
-
-        public void propertyChange(PropertyChangeEvent e) {
-            String prop = e.getPropertyName();
-            if(prop == JFileChooser.CHOOSABLE_FILE_FILTER_CHANGED_PROPERTY) {
-                filters = (FileFilter[]) e.getNewValue();
-                fireContentsChanged(this, -1, -1);
-            } else if (prop == JFileChooser.FILE_FILTER_CHANGED_PROPERTY) {
-                fireContentsChanged(this, -1, -1);
-            }
-        }
-
-        public void setSelectedItem(Object filter) {
-            if(filter != null) {
-                getFileChooser().setFileFilter((FileFilter) filter);
-                fireContentsChanged(this, -1, -1);
-            }
-        }
-
-        public Object getSelectedItem() {
-            // Ensure that the current filter is in the list.
-            // NOTE: we shouldnt' have to do this, since JFileChooser adds
-            // the filter to the choosable filters list when the filter
-            // is set. Lets be paranoid just in case someone overrides
-            // setFileFilter in JFileChooser.
-            FileFilter currentFilter = getFileChooser().getFileFilter();
-            boolean found = false;
-            if(currentFilter != null) {
-                for (FileFilter filter : filters) {
-                    if (filter == currentFilter) {
-                        found = true;
-                    }
-                }
-                if(found == false) {
-                    getFileChooser().addChoosableFileFilter(currentFilter);
-                }
-            }
-            return getFileChooser().getFileFilter();
-        }
-
-        public int getSize() {
-            if(filters != null) {
-                return filters.length;
-            } else {
-                return 0;
-            }
-        }
-
-        public FileFilter getElementAt(int index) {
-            if(index > getSize() - 1) {
-                // This shouldn't happen. Try to recover gracefully.
-                return getFileChooser().getFileFilter();
-            }
-            if(filters != null) {
-                return filters[index];
-            } else {
-                return null;
-            }
-        }
-    }
-
-    public void valueChanged(ListSelectionEvent e) {
-        JFileChooser fc = getFileChooser();
-        File f = fc.getSelectedFile();
-        if (!e.getValueIsAdjusting() && f != null && !getFileChooser().isTraversable(f)) {
-            setFileName(fileNameString(f));
-        }
-    }
-
-    /**
-     * Acts when DirectoryComboBox has changed the selected item.
-     */
-    protected class DirectoryComboBoxAction implements ActionListener {
-
-
-
-
-        public void actionPerformed(ActionEvent e) {
-            File f = (File)directoryComboBox.getSelectedItem();
-            getFileChooser().setCurrentDirectory(f);
-        }
-    }
-
-    protected JButton getApproveButton(JFileChooser fc) {
-        return approveButton;
-    }
-
-    public FileView getFileView(JFileChooser fc) {
-        return fileView;
-    }
-
-    // ***********************
-    // * FileView operations *
-    // ***********************
-    protected class WindowsFileView extends BasicFileView {
-        /* FileView type descriptions */
-
-        public Icon getIcon(File f) {
-            Icon icon = getCachedIcon(f);
-            if (icon != null) {
-                return icon;
-            }
-            if (f != null) {
-                icon = getFileChooser().getFileSystemView().getSystemIcon(f);
-            }
-            if (icon == null) {
-                icon = super.getIcon(f);
-            }
-            cacheIcon(f, icon);
-            return icon;
-        }
-    }
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsGraphicsUtils.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,236 +0,0 @@
-/*
- * Copyright (c) 2000, 2015, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import sun.swing.SwingUtilities2;
-
-import java.awt.*;
-
-import javax.swing.*;
-import javax.swing.plaf.UIResource;
-
-import static com.sun.java.swing.plaf.windows.TMSchema.*;
-
-/**
- * A collection of static utility methods used for rendering the Windows look
- * and feel.
- *
- * @author Mark Davidson
- * @since 1.4
- */
-public class WindowsGraphicsUtils {
-
-    /**
-     * Renders a text String in Windows without the mnemonic.
-     * This is here because the WindowsUI hierarchy doesn't match the Component hierarchy. All
-     * the overriden paintText methods of the ButtonUI delegates will call this static method.
-     *
-     * @param g Graphics context
-     * @param b Current button to render
-     * @param textRect Bounding rectangle to render the text.
-     * @param text String to render
-     */
-    public static void paintText(Graphics g, AbstractButton b,
-                                        Rectangle textRect, String text,
-                                        int textShiftOffset) {
-        FontMetrics fm = SwingUtilities2.getFontMetrics(b, g);
-
-        int mnemIndex = b.getDisplayedMnemonicIndex();
-        // W2K Feature: Check to see if the Underscore should be rendered.
-        if (WindowsLookAndFeel.isMnemonicHidden() == true) {
-            mnemIndex = -1;
-        }
-
-        XPStyle xp = XPStyle.getXP();
-        if (xp != null && !(b instanceof JMenuItem)) {
-            paintXPText(b, g, textRect.x + textShiftOffset,
-                    textRect.y + fm.getAscent() + textShiftOffset,
-                    text, mnemIndex);
-        } else {
-            paintClassicText(b, g, textRect.x + textShiftOffset,
-                    textRect.y + fm.getAscent() + textShiftOffset,
-                    text, mnemIndex);
-        }
-    }
-
-    static void paintClassicText(AbstractButton b, Graphics g, int x, int y,
-                                 String text, int mnemIndex) {
-        ButtonModel model = b.getModel();
-
-        /* Draw the Text */
-        Color color = b.getForeground();
-        if(model.isEnabled()) {
-            /*** paint the text normally */
-            if(!(b instanceof JMenuItem && model.isArmed())
-                && !(b instanceof JMenu && (model.isSelected() || model.isRollover()))) {
-                /* We shall not set foreground color for selected menu or
-                 * armed menuitem. Foreground must be set in appropriate
-                 * Windows* class because these colors passes from
-                 * BasicMenuItemUI as protected fields and we can't
-                 * reach them from this class */
-                g.setColor(b.getForeground());
-            }
-            SwingUtilities2.drawStringUnderlineCharAt(b, g,text, mnemIndex, x, y);
-        } else {        /*** paint the text disabled ***/
-            color = getDisabledTextColor(b);
-            if (color == null) {
-                color = UIManager.getColor("Button.shadow");
-            }
-            Color shadow = UIManager.getColor("Button.disabledShadow");
-            if(model.isArmed()) {
-                color = UIManager.getColor("Button.disabledForeground");
-            } else {
-                if (shadow == null) {
-                    shadow = b.getBackground().darker();
-                }
-                g.setColor(shadow);
-                SwingUtilities2.drawStringUnderlineCharAt(b, g, text, mnemIndex,
-                                                          x + 1, y + 1);
-            }
-            if (color == null) {
-                color = b.getBackground().brighter();
-            }
-            g.setColor(color);
-            SwingUtilities2.drawStringUnderlineCharAt(b, g, text, mnemIndex, x, y);
-        }
-    }
-
-    private static Color getDisabledTextColor(AbstractButton b) {
-        if (b instanceof JCheckBox) {
-            return UIManager.getColor("CheckBox.disabledText");
-        } else if (b instanceof JRadioButton) {
-            return UIManager.getColor("RadioButton.disabledText");
-        } else if (b instanceof JToggleButton) {
-            return  UIManager.getColor("ToggleButton.disabledText");
-        } else if (b instanceof JButton) {
-            return UIManager.getColor("Button.disabledText");
-        }
-        return null;
-    }
-
-    static void paintXPText(AbstractButton b, Graphics g, int x, int y,
-                            String text, int mnemIndex) {
-        Part part = WindowsButtonUI.getXPButtonType(b);
-        State state = WindowsButtonUI.getXPButtonState(b);
-        paintXPText(b, part, state, g, x, y, text, mnemIndex);
-    }
-
-    static void paintXPText(AbstractButton b, Part part, State state,
-            Graphics g, int x, int y, String text, int mnemIndex) {
-        XPStyle xp = XPStyle.getXP();
-        if (xp == null) {
-            return;
-        }
-        Color textColor;
-        if (b.isEnabled()) {
-            textColor = b.getForeground();
-        }
-        else {
-            textColor = getDisabledTextColor(b);
-        }
-
-        if (textColor == null || textColor instanceof UIResource) {
-            textColor = xp.getColor(b, part, state, Prop.TEXTCOLOR, b.getForeground());
-            // to work around an apparent bug in Windows, use the pushbutton
-            // color for disabled toolbar buttons if the disabled color is the
-            // same as the enabled color
-            if (part == Part.TP_BUTTON && state == State.DISABLED) {
-                Color enabledColor = xp.getColor(b, part, State.NORMAL,
-                                     Prop.TEXTCOLOR, b.getForeground());
-                if(textColor.equals(enabledColor)) {
-                    textColor = xp.getColor(b, Part.BP_PUSHBUTTON, state,
-                                Prop.TEXTCOLOR, textColor);
-                }
-            }
-            // only draw shadow if developer hasn't changed the foreground color
-            // and if the current style has text shadows.
-            TypeEnum shadowType = xp.getTypeEnum(b, part,
-                                                 state, Prop.TEXTSHADOWTYPE);
-            if (shadowType == TypeEnum.TST_SINGLE ||
-                        shadowType == TypeEnum.TST_CONTINUOUS) {
-                Color shadowColor = xp.getColor(b, part, state,
-                                                Prop.TEXTSHADOWCOLOR, Color.black);
-                Point offset = xp.getPoint(b, part, state, Prop.TEXTSHADOWOFFSET);
-                if (offset != null) {
-                    g.setColor(shadowColor);
-                    SwingUtilities2.drawStringUnderlineCharAt(b, g, text, mnemIndex,
-                                                              x + offset.x,
-                                                              y + offset.y);
-                }
-            }
-        }
-
-        g.setColor(textColor);
-        SwingUtilities2.drawStringUnderlineCharAt(b, g, text, mnemIndex, x, y);
-    }
-
-    static boolean isLeftToRight(Component c) {
-        return c.getComponentOrientation().isLeftToRight();
-    }
-
-    /*
-     * Repaints all the components with the mnemonics in the given window and
-     * all its owned windows.
-     */
-    static void repaintMnemonicsInWindow(Window w) {
-        if(w == null || !w.isShowing()) {
-            return;
-        }
-
-        Window[] ownedWindows = w.getOwnedWindows();
-        for(int i=0;i<ownedWindows.length;i++) {
-            repaintMnemonicsInWindow(ownedWindows[i]);
-        }
-
-        repaintMnemonicsInContainer(w);
-    }
-
-    /*
-     * Repaints all the components with the mnemonics in container.
-     * Recursively searches for all the subcomponents.
-     */
-    static void repaintMnemonicsInContainer(Container cont) {
-        Component c;
-        for(int i=0; i<cont.getComponentCount(); i++) {
-            c = cont.getComponent(i);
-            if(c == null || !c.isVisible()) {
-                continue;
-            }
-            if(c instanceof AbstractButton
-               && ((AbstractButton)c).getMnemonic() != '\0') {
-                c.repaint();
-                continue;
-            } else if(c instanceof JLabel
-                      && ((JLabel)c).getDisplayedMnemonic() != '\0') {
-                c.repaint();
-                continue;
-            }
-            if(c instanceof Container) {
-                repaintMnemonicsInContainer((Container)c);
-            }
-        }
-    }
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsIconFactory.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,974 +0,0 @@
-/*
- * Copyright (c) 1998, 2014, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import javax.swing.*;
-import javax.swing.plaf.ButtonUI;
-import javax.swing.plaf.UIResource;
-
-import java.awt.*;
-import java.io.Serializable;
-
-import static com.sun.java.swing.plaf.windows.TMSchema.*;
-import static com.sun.java.swing.plaf.windows.XPStyle.Skin;
-
-import sun.swing.MenuItemCheckIconFactory;
-import sun.swing.SwingUtilities2;
-
-/**
- * Factory object that can vend Icons appropriate for the Windows {@literal L & F}.
- * <p>
- * <strong>Warning:</strong>
- * Serialized objects of this class will not be compatible with
- * future Swing releases.  The current serialization support is appropriate
- * for short term storage or RMI between applications running the same
- * version of Swing.  A future release of Swing will provide support for
- * long term persistence.
- *
- * @author David Kloba
- * @author Georges Saab
- * @author Rich Schiavi
- */
-@SuppressWarnings("serial") // Same-version serialization only
-public class WindowsIconFactory implements Serializable
-{
-    private static Icon frame_closeIcon;
-    private static Icon frame_iconifyIcon;
-    private static Icon frame_maxIcon;
-    private static Icon frame_minIcon;
-    private static Icon frame_resizeIcon;
-    private static Icon checkBoxIcon;
-    private static Icon radioButtonIcon;
-    private static Icon checkBoxMenuItemIcon;
-    private static Icon radioButtonMenuItemIcon;
-    private static Icon menuItemCheckIcon;
-    private static Icon menuItemArrowIcon;
-    private static Icon menuArrowIcon;
-    private static VistaMenuItemCheckIconFactory menuItemCheckIconFactory;
-
-    public static Icon getMenuItemCheckIcon() {
-        if (menuItemCheckIcon == null) {
-            menuItemCheckIcon = new MenuItemCheckIcon();
-        }
-        return menuItemCheckIcon;
-    }
-
-    public static Icon getMenuItemArrowIcon() {
-        if (menuItemArrowIcon == null) {
-            menuItemArrowIcon = new MenuItemArrowIcon();
-        }
-        return menuItemArrowIcon;
-    }
-
-    public static Icon getMenuArrowIcon() {
-        if (menuArrowIcon == null) {
-            menuArrowIcon = new MenuArrowIcon();
-        }
-        return menuArrowIcon;
-    }
-
-    public static Icon getCheckBoxIcon() {
-        if (checkBoxIcon == null) {
-            checkBoxIcon = new CheckBoxIcon();
-        }
-        return checkBoxIcon;
-    }
-
-    public static Icon getRadioButtonIcon() {
-        if (radioButtonIcon == null) {
-            radioButtonIcon = new RadioButtonIcon();
-        }
-        return radioButtonIcon;
-    }
-
-    public static Icon getCheckBoxMenuItemIcon() {
-        if (checkBoxMenuItemIcon == null) {
-            checkBoxMenuItemIcon = new CheckBoxMenuItemIcon();
-        }
-        return checkBoxMenuItemIcon;
-    }
-
-    public static Icon getRadioButtonMenuItemIcon() {
-        if (radioButtonMenuItemIcon == null) {
-            radioButtonMenuItemIcon = new RadioButtonMenuItemIcon();
-        }
-        return radioButtonMenuItemIcon;
-    }
-
-    static
-    synchronized VistaMenuItemCheckIconFactory getMenuItemCheckIconFactory() {
-        if (menuItemCheckIconFactory == null) {
-            menuItemCheckIconFactory =
-                new VistaMenuItemCheckIconFactory();
-        }
-        return menuItemCheckIconFactory;
-    }
-
-    public static Icon createFrameCloseIcon() {
-        if (frame_closeIcon == null) {
-            frame_closeIcon = new FrameButtonIcon(Part.WP_CLOSEBUTTON);
-        }
-        return frame_closeIcon;
-    }
-
-    public static Icon createFrameIconifyIcon() {
-        if (frame_iconifyIcon == null) {
-            frame_iconifyIcon = new FrameButtonIcon(Part.WP_MINBUTTON);
-        }
-        return frame_iconifyIcon;
-    }
-
-    public static Icon createFrameMaximizeIcon() {
-        if (frame_maxIcon == null) {
-            frame_maxIcon = new FrameButtonIcon(Part.WP_MAXBUTTON);
-        }
-        return frame_maxIcon;
-    }
-
-    public static Icon createFrameMinimizeIcon() {
-        if (frame_minIcon == null) {
-            frame_minIcon = new FrameButtonIcon(Part.WP_RESTOREBUTTON);
-        }
-        return frame_minIcon;
-    }
-
-    public static Icon createFrameResizeIcon() {
-        if(frame_resizeIcon == null)
-            frame_resizeIcon = new ResizeIcon();
-        return frame_resizeIcon;
-    }
-
-
-    @SuppressWarnings("serial") // Same-version serialization only
-    private static class FrameButtonIcon implements Icon, Serializable {
-        private Part part;
-
-        private FrameButtonIcon(Part part) {
-            this.part = part;
-        }
-
-        public void paintIcon(Component c, Graphics g, int x0, int y0) {
-            int width = getIconWidth();
-            int height = getIconHeight();
-
-            XPStyle xp = XPStyle.getXP();
-            if (xp != null) {
-                Skin skin = xp.getSkin(c, part);
-                AbstractButton b = (AbstractButton)c;
-                ButtonModel model = b.getModel();
-
-                // Find out if frame is inactive
-                JInternalFrame jif = (JInternalFrame)SwingUtilities.
-                                        getAncestorOfClass(JInternalFrame.class, b);
-                boolean jifSelected = (jif != null && jif.isSelected());
-
-                State state;
-                if (jifSelected) {
-                    if (!model.isEnabled()) {
-                        state = State.DISABLED;
-                    } else if (model.isArmed() && model.isPressed()) {
-                        state = State.PUSHED;
-                    } else if (model.isRollover()) {
-                        state = State.HOT;
-                    } else {
-                        state = State.NORMAL;
-                    }
-                } else {
-                    if (!model.isEnabled()) {
-                        state = State.INACTIVEDISABLED;
-                    } else if (model.isArmed() && model.isPressed()) {
-                        state = State.INACTIVEPUSHED;
-                    } else if (model.isRollover()) {
-                        state = State.INACTIVEHOT;
-                    } else {
-                        state = State.INACTIVENORMAL;
-                    }
-                }
-                skin.paintSkin(g, 0, 0, width, height, state);
-            } else {
-                g.setColor(Color.black);
-                int x = width / 12 + 2;
-                int y = height / 5;
-                int h = height - y * 2 - 1;
-                int w = width * 3/4 -3;
-                int thickness2 = Math.max(height / 8, 2);
-                int thickness  = Math.max(width / 15, 1);
-                if (part == Part.WP_CLOSEBUTTON) {
-                    int lineWidth;
-                    if      (width > 47) lineWidth = 6;
-                    else if (width > 37) lineWidth = 5;
-                    else if (width > 26) lineWidth = 4;
-                    else if (width > 16) lineWidth = 3;
-                    else if (width > 12) lineWidth = 2;
-                    else                 lineWidth = 1;
-                    y = height / 12 + 2;
-                    if (lineWidth == 1) {
-                        if (w % 2 == 1) { x++; w++; }
-                        g.drawLine(x,     y, x+w-2, y+w-2);
-                        g.drawLine(x+w-2, y, x,     y+w-2);
-                    } else if (lineWidth == 2) {
-                        if (w > 6) { x++; w--; }
-                        g.drawLine(x,     y, x+w-2, y+w-2);
-                        g.drawLine(x+w-2, y, x,     y+w-2);
-                        g.drawLine(x+1,   y, x+w-1, y+w-2);
-                        g.drawLine(x+w-1, y, x+1,   y+w-2);
-                    } else {
-                        x += 2; y++; w -= 2;
-                        g.drawLine(x,     y,   x+w-1, y+w-1);
-                        g.drawLine(x+w-1, y,   x,     y+w-1);
-                        g.drawLine(x+1,   y,   x+w-1, y+w-2);
-                        g.drawLine(x+w-2, y,   x,     y+w-2);
-                        g.drawLine(x,     y+1, x+w-2, y+w-1);
-                        g.drawLine(x+w-1, y+1, x+1,   y+w-1);
-                        for (int i = 4; i <= lineWidth; i++) {
-                            g.drawLine(x+i-2,   y,     x+w-1,   y+w-i+1);
-                            g.drawLine(x,       y+i-2, x+w-i+1, y+w-1);
-                            g.drawLine(x+w-i+1, y,     x,       y+w-i+1);
-                            g.drawLine(x+w-1,   y+i-2, x+i-2,   y+w-1);
-                        }
-                    }
-                } else if (part == Part.WP_MINBUTTON) {
-                    g.fillRect(x, y+h-thickness2, w-w/3, thickness2);
-                } else if (part == Part.WP_MAXBUTTON) {
-                    g.fillRect(x, y, w, thickness2);
-                    g.fillRect(x, y, thickness, h);
-                    g.fillRect(x+w-thickness, y, thickness, h);
-                    g.fillRect(x, y+h-thickness, w, thickness);
-                } else if (part == Part.WP_RESTOREBUTTON) {
-                    g.fillRect(x+w/3, y, w-w/3, thickness2);
-                    g.fillRect(x+w/3, y, thickness, h/3);
-                    g.fillRect(x+w-thickness, y, thickness, h-h/3);
-                    g.fillRect(x+w-w/3, y+h-h/3-thickness, w/3, thickness);
-
-                    g.fillRect(x, y+h/3, w-w/3, thickness2);
-                    g.fillRect(x, y+h/3, thickness, h-h/3);
-                    g.fillRect(x+w-w/3-thickness, y+h/3, thickness, h-h/3);
-                    g.fillRect(x, y+h-thickness, w-w/3, thickness);
-                }
-            }
-        }
-
-        public int getIconWidth() {
-            int width;
-            if (XPStyle.getXP() != null) {
-                // Fix for XP bug where sometimes these sizes aren't updated properly
-                // Assume for now that height is correct and derive width using the
-                // ratio from the uxtheme part
-                width = UIManager.getInt("InternalFrame.titleButtonHeight") -2;
-                Dimension d = XPStyle.getPartSize(Part.WP_CLOSEBUTTON, State.NORMAL);
-                if (d != null && d.width != 0 && d.height != 0) {
-                    width = (int) ((float) width * d.width / d.height);
-                }
-            } else {
-                width = UIManager.getInt("InternalFrame.titleButtonWidth") -2;
-            }
-            if (XPStyle.getXP() != null) {
-                width -= 2;
-            }
-            return width;
-        }
-
-        public int getIconHeight() {
-            int height = UIManager.getInt("InternalFrame.titleButtonHeight")-4;
-            return height;
-        }
-    }
-
-
-
-        @SuppressWarnings("serial") // Same-version serialization only
-        private static class ResizeIcon implements Icon, Serializable {
-            public void paintIcon(Component c, Graphics g, int x, int y) {
-                g.setColor(UIManager.getColor("InternalFrame.resizeIconHighlight"));
-                g.drawLine(0, 11, 11, 0);
-                g.drawLine(4, 11, 11, 4);
-                g.drawLine(8, 11, 11, 8);
-
-                g.setColor(UIManager.getColor("InternalFrame.resizeIconShadow"));
-                g.drawLine(1, 11, 11, 1);
-                g.drawLine(2, 11, 11, 2);
-                g.drawLine(5, 11, 11, 5);
-                g.drawLine(6, 11, 11, 6);
-                g.drawLine(9, 11, 11, 9);
-                g.drawLine(10, 11, 11, 10);
-            }
-            public int getIconWidth() { return 13; }
-            public int getIconHeight() { return 13; }
-        };
-
-    @SuppressWarnings("serial") // Same-version serialization only
-    private static class CheckBoxIcon implements Icon, Serializable
-    {
-        static final int csize = 13;
-        public void paintIcon(Component c, Graphics g, int x, int y) {
-            JCheckBox cb = (JCheckBox) c;
-            ButtonModel model = cb.getModel();
-            XPStyle xp = XPStyle.getXP();
-
-            if (xp != null) {
-                State state;
-                if (model.isSelected()) {
-                    state = State.CHECKEDNORMAL;
-                    if (!model.isEnabled()) {
-                        state = State.CHECKEDDISABLED;
-                    } else if (model.isPressed() && model.isArmed()) {
-                        state = State.CHECKEDPRESSED;
-                    } else if (model.isRollover()) {
-                        state = State.CHECKEDHOT;
-                    }
-                } else {
-                    state = State.UNCHECKEDNORMAL;
-                    if (!model.isEnabled()) {
-                        state = State.UNCHECKEDDISABLED;
-                    } else if (model.isPressed() && model.isArmed()) {
-                        state = State.UNCHECKEDPRESSED;
-                    } else if (model.isRollover()) {
-                        state = State.UNCHECKEDHOT;
-                    }
-                }
-                Part part = Part.BP_CHECKBOX;
-                xp.getSkin(c, part).paintSkin(g, x, y, state);
-            } else {
-                // outer bevel
-                if(!cb.isBorderPaintedFlat()) {
-                    // Outer top/left
-                    g.setColor(UIManager.getColor("CheckBox.shadow"));
-                    g.drawLine(x, y, x+11, y);
-                    g.drawLine(x, y+1, x, y+11);
-
-                    // Outer bottom/right
-                    g.setColor(UIManager.getColor("CheckBox.highlight"));
-                    g.drawLine(x+12, y, x+12, y+12);
-                    g.drawLine(x, y+12, x+11, y+12);
-
-                    // Inner top.left
-                    g.setColor(UIManager.getColor("CheckBox.darkShadow"));
-                    g.drawLine(x+1, y+1, x+10, y+1);
-                    g.drawLine(x+1, y+2, x+1, y+10);
-
-                    // Inner bottom/right
-                    g.setColor(UIManager.getColor("CheckBox.light"));
-                    g.drawLine(x+1, y+11, x+11, y+11);
-                    g.drawLine(x+11, y+1, x+11, y+10);
-
-                    // inside box
-                    if((model.isPressed() && model.isArmed()) || !model.isEnabled()) {
-                        g.setColor(UIManager.getColor("CheckBox.background"));
-                    } else {
-                        g.setColor(UIManager.getColor("CheckBox.interiorBackground"));
-                    }
-                    g.fillRect(x+2, y+2, csize-4, csize-4);
-                } else {
-                    g.setColor(UIManager.getColor("CheckBox.shadow"));
-                    g.drawRect(x+1, y+1, csize-3, csize-3);
-
-                    if((model.isPressed() && model.isArmed()) || !model.isEnabled()) {
-                        g.setColor(UIManager.getColor("CheckBox.background"));
-                    } else {
-                        g.setColor(UIManager.getColor("CheckBox.interiorBackground"));
-                    }
-                    g.fillRect(x+2, y+2, csize-4, csize-4);
-                }
-
-                if(model.isEnabled()) {
-                    g.setColor(UIManager.getColor("CheckBox.foreground"));
-                } else {
-                    g.setColor(UIManager.getColor("CheckBox.shadow"));
-                }
-
-                // paint check
-                if (model.isSelected()) {
-                    if (SwingUtilities2.isScaledGraphics(g)) {
-                        int[] xPoints = {3, 5, 9, 9, 5, 3};
-                        int[] yPoints = {5, 7, 3, 5, 9, 7};
-                        g.translate(x, y);
-                        g.fillPolygon(xPoints, yPoints, 6);
-                        g.drawPolygon(xPoints, yPoints, 6);
-                        g.translate(-x, -y);
-                    } else {
-                        g.drawLine(x + 9, y + 3, x + 9, y + 3);
-                        g.drawLine(x + 8, y + 4, x + 9, y + 4);
-                        g.drawLine(x + 7, y + 5, x + 9, y + 5);
-                        g.drawLine(x + 6, y + 6, x + 8, y + 6);
-                        g.drawLine(x + 3, y + 7, x + 7, y + 7);
-                        g.drawLine(x + 4, y + 8, x + 6, y + 8);
-                        g.drawLine(x + 5, y + 9, x + 5, y + 9);
-                        g.drawLine(x + 3, y + 5, x + 3, y + 5);
-                        g.drawLine(x + 3, y + 6, x + 4, y + 6);
-                    }
-                }
-            }
-        }
-
-        public int getIconWidth() {
-            XPStyle xp = XPStyle.getXP();
-            if (xp != null) {
-                return xp.getSkin(null, Part.BP_CHECKBOX).getWidth();
-            } else {
-                return csize;
-            }
-        }
-
-        public int getIconHeight() {
-            XPStyle xp = XPStyle.getXP();
-            if (xp != null) {
-                return xp.getSkin(null, Part.BP_CHECKBOX).getHeight();
-            } else {
-                return csize;
-            }
-        }
-    }
-
-    @SuppressWarnings("serial") // Same-version serialization only
-    private static class RadioButtonIcon implements Icon, UIResource, Serializable
-    {
-        public void paintIcon(Component c, Graphics g, int x, int y) {
-            AbstractButton b = (AbstractButton) c;
-            ButtonModel model = b.getModel();
-            XPStyle xp = XPStyle.getXP();
-
-            if (xp != null) {
-                Part part = Part.BP_RADIOBUTTON;
-                Skin skin = xp.getSkin(b, part);
-                State state;
-                int index = 0;
-                if (model.isSelected()) {
-                    state = State.CHECKEDNORMAL;
-                    if (!model.isEnabled()) {
-                        state = State.CHECKEDDISABLED;
-                    } else if (model.isPressed() && model.isArmed()) {
-                        state = State.CHECKEDPRESSED;
-                    } else if (model.isRollover()) {
-                        state = State.CHECKEDHOT;
-                    }
-                } else {
-                    state = State.UNCHECKEDNORMAL;
-                    if (!model.isEnabled()) {
-                        state = State.UNCHECKEDDISABLED;
-                    } else if (model.isPressed() && model.isArmed()) {
-                        state = State.UNCHECKEDPRESSED;
-                    } else if (model.isRollover()) {
-                        state = State.UNCHECKEDHOT;
-                    }
-                }
-                skin.paintSkin(g, x, y, state);
-            } else {
-                // fill interior
-                if((model.isPressed() && model.isArmed()) || !model.isEnabled()) {
-                    g.setColor(UIManager.getColor("RadioButton.background"));
-                } else {
-                    g.setColor(UIManager.getColor("RadioButton.interiorBackground"));
-                }
-                g.fillRect(x+2, y+2, 8, 8);
-
-
-                boolean isScaledGraphics = SwingUtilities2.isScaledGraphics(g);
-
-                if (isScaledGraphics) {
-
-                    Graphics2D g2d = (Graphics2D) g;
-                    Stroke oldStroke = g2d.getStroke();
-                    g2d.setStroke(new BasicStroke(1.03f, BasicStroke.CAP_ROUND,
-                                                  BasicStroke.JOIN_ROUND));
-                    Object aaHint = g2d.getRenderingHint(RenderingHints.KEY_ANTIALIASING);
-                    g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
-                                         RenderingHints.VALUE_ANTIALIAS_ON);
-
-                    // outter left arc
-                    g.setColor(UIManager.getColor("RadioButton.shadow"));
-                    g.drawArc(x, y, 11, 11, 45, 180);
-                    // outter right arc
-                    g.setColor(UIManager.getColor("RadioButton.highlight"));
-                    g.drawArc(x, y, 11, 11, 45, -180);
-                    // inner left arc
-                    g.setColor(UIManager.getColor("RadioButton.darkShadow"));
-                    g.drawArc(x + 1, y + 1, 9, 9, 45, 180);
-                    // inner right arc
-                    g.setColor(UIManager.getColor("RadioButton.light"));
-                    g.drawArc(x + 1, y + 1, 9, 9, 45, -180);
-
-                    g2d.setStroke(oldStroke);
-
-                    if (model.isSelected()) {
-                        if (model.isEnabled()) {
-                            g.setColor(UIManager.getColor("RadioButton.foreground"));
-                        } else {
-                            g.setColor(UIManager.getColor("RadioButton.shadow"));
-                        }
-                        g.fillOval(x + 3, y + 3, 5, 5);
-                    }
-                    g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, aaHint);
-
-                } else {
-
-                    // outter left arc
-                    g.setColor(UIManager.getColor("RadioButton.shadow"));
-                    g.drawLine(x+4, y+0, x+7, y+0);
-                    g.drawLine(x+2, y+1, x+3, y+1);
-                    g.drawLine(x+8, y+1, x+9, y+1);
-                    g.drawLine(x+1, y+2, x+1, y+3);
-                    g.drawLine(x+0, y+4, x+0, y+7);
-                    g.drawLine(x+1, y+8, x+1, y+9);
-
-                    // outter right arc
-                    g.setColor(UIManager.getColor("RadioButton.highlight"));
-                    g.drawLine(x+2, y+10, x+3, y+10);
-                    g.drawLine(x+4, y+11, x+7, y+11);
-                    g.drawLine(x+8, y+10, x+9, y+10);
-                    g.drawLine(x+10, y+9, x+10, y+8);
-                    g.drawLine(x+11, y+7, x+11, y+4);
-                    g.drawLine(x+10, y+3, x+10, y+2);
-
-
-                    // inner left arc
-                    g.setColor(UIManager.getColor("RadioButton.darkShadow"));
-                    g.drawLine(x+4, y+1, x+7, y+1);
-                    g.drawLine(x+2, y+2, x+3, y+2);
-                    g.drawLine(x+8, y+2, x+9, y+2);
-                    g.drawLine(x+2, y+3, x+2, y+3);
-                    g.drawLine(x+1, y+4, x+1, y+7);
-                    g.drawLine(x+2, y+8, x+2, y+8);
-
-
-                    // inner right arc
-                    g.setColor(UIManager.getColor("RadioButton.light"));
-                    g.drawLine(x+2,  y+9,  x+3,  y+9);
-                    g.drawLine(x+4,  y+10, x+7,  y+10);
-                    g.drawLine(x+8,  y+9,  x+9,  y+9);
-                    g.drawLine(x+9,  y+8,  x+9,  y+8);
-                    g.drawLine(x+10, y+7,  x+10, y+4);
-                    g.drawLine(x+9,  y+3,  x+9,  y+3);
-
-
-                     // indicate whether selected or not
-                    if (model.isSelected()) {
-                        if (model.isEnabled()) {
-                            g.setColor(UIManager.getColor("RadioButton.foreground"));
-                        } else {
-                            g.setColor(UIManager.getColor("RadioButton.shadow"));
-                        }
-                        g.fillRect(x+4, y+5, 4, 2);
-                        g.fillRect(x+5, y+4, 2, 4);
-                    }
-                }
-            }
-        }
-
-        public int getIconWidth() {
-            XPStyle xp = XPStyle.getXP();
-            if (xp != null) {
-                return xp.getSkin(null, Part.BP_RADIOBUTTON).getWidth();
-            } else {
-                return 13;
-            }
-        }
-
-        public int getIconHeight() {
-            XPStyle xp = XPStyle.getXP();
-            if (xp != null) {
-                return xp.getSkin(null, Part.BP_RADIOBUTTON).getHeight();
-            } else {
-                return 13;
-            }
-        }
-    } // end class RadioButtonIcon
-
-
-    @SuppressWarnings("serial") // Same-version serialization only
-    private static class CheckBoxMenuItemIcon implements Icon, UIResource, Serializable
-    {
-        public void paintIcon(Component c, Graphics g, int x, int y) {
-            AbstractButton b = (AbstractButton) c;
-            ButtonModel model = b.getModel();
-            boolean isSelected = model.isSelected();
-            if (isSelected) {
-                y = y - getIconHeight() / 2;
-                g.drawLine(x+9, y+3, x+9, y+3);
-                g.drawLine(x+8, y+4, x+9, y+4);
-                g.drawLine(x+7, y+5, x+9, y+5);
-                g.drawLine(x+6, y+6, x+8, y+6);
-                g.drawLine(x+3, y+7, x+7, y+7);
-                g.drawLine(x+4, y+8, x+6, y+8);
-                g.drawLine(x+5, y+9, x+5, y+9);
-                g.drawLine(x+3, y+5, x+3, y+5);
-                g.drawLine(x+3, y+6, x+4, y+6);
-            }
-        }
-        public int getIconWidth() { return 9; }
-        public int getIconHeight() { return 9; }
-
-    } // End class CheckBoxMenuItemIcon
-
-
-    @SuppressWarnings("serial") // Same-version serialization only
-    private static class RadioButtonMenuItemIcon implements Icon, UIResource, Serializable
-    {
-        public void paintIcon(Component c, Graphics g, int x, int y) {
-            AbstractButton b = (AbstractButton) c;
-            ButtonModel model = b.getModel();
-            if (b.isSelected() == true) {
-               g.fillRoundRect(x+3,y+3, getIconWidth()-6, getIconHeight()-6,
-                               4, 4);
-            }
-        }
-        public int getIconWidth() { return 12; }
-        public int getIconHeight() { return 12; }
-
-    } // End class RadioButtonMenuItemIcon
-
-
-    @SuppressWarnings("serial") // Same-version serialization only
-    private static class MenuItemCheckIcon implements Icon, UIResource, Serializable{
-        public void paintIcon(Component c, Graphics g, int x, int y) {
-            /* For debugging:
-               Color oldColor = g.getColor();
-            g.setColor(Color.orange);
-            g.fill3DRect(x,y,getIconWidth(), getIconHeight(), true);
-            g.setColor(oldColor);
-            */
-        }
-        public int getIconWidth() { return 9; }
-        public int getIconHeight() { return 9; }
-
-    } // End class MenuItemCheckIcon
-
-    @SuppressWarnings("serial") // Same-version serialization only
-    private static class MenuItemArrowIcon implements Icon, UIResource, Serializable {
-        public void paintIcon(Component c, Graphics g, int x, int y) {
-            /* For debugging:
-            Color oldColor = g.getColor();
-            g.setColor(Color.green);
-            g.fill3DRect(x,y,getIconWidth(), getIconHeight(), true);
-            g.setColor(oldColor);
-            */
-        }
-        public int getIconWidth() { return 4; }
-        public int getIconHeight() { return 8; }
-
-    } // End class MenuItemArrowIcon
-
-    @SuppressWarnings("serial") // Same-version serialization only
-    private static class MenuArrowIcon implements Icon, UIResource, Serializable {
-        public void paintIcon(Component c, Graphics g, int x, int y) {
-            XPStyle xp = XPStyle.getXP();
-            if (WindowsMenuItemUI.isVistaPainting(xp)) {
-                State state = State.NORMAL;
-                if (c instanceof JMenuItem) {
-                    state = ((JMenuItem) c).getModel().isEnabled()
-                    ? State.NORMAL : State.DISABLED;
-                }
-                Skin skin = xp.getSkin(c, Part.MP_POPUPSUBMENU);
-                if (WindowsGraphicsUtils.isLeftToRight(c)) {
-                    skin.paintSkin(g, x, y, state);
-                } else {
-                    Graphics2D g2d = (Graphics2D)g.create();
-                    g2d.translate(x + skin.getWidth(), y);
-                    g2d.scale(-1, 1);
-                    skin.paintSkin(g2d, 0, 0, state);
-                    g2d.dispose();
-                }
-            } else {
-                g.translate(x,y);
-                if( WindowsGraphicsUtils.isLeftToRight(c) ) {
-                    g.drawLine( 0, 0, 0, 7 );
-                    g.drawLine( 1, 1, 1, 6 );
-                    g.drawLine( 2, 2, 2, 5 );
-                    g.drawLine( 3, 3, 3, 4 );
-                } else {
-                    g.drawLine( 4, 0, 4, 7 );
-                    g.drawLine( 3, 1, 3, 6 );
-                    g.drawLine( 2, 2, 2, 5 );
-                    g.drawLine( 1, 3, 1, 4 );
-                }
-                g.translate(-x,-y);
-            }
-        }
-        public int getIconWidth() {
-            XPStyle xp = XPStyle.getXP();
-            if (WindowsMenuItemUI.isVistaPainting(xp)) {
-                Skin skin = xp.getSkin(null, Part.MP_POPUPSUBMENU);
-                return skin.getWidth();
-            } else {
-                return 4;
-            }
-        }
-        public int getIconHeight() {
-            XPStyle xp = XPStyle.getXP();
-            if (WindowsMenuItemUI.isVistaPainting(xp)) {
-                Skin skin = xp.getSkin(null, Part.MP_POPUPSUBMENU);
-                return skin.getHeight();
-            } else {
-                return 8;
-            }
-        }
-    } // End class MenuArrowIcon
-
-    static class VistaMenuItemCheckIconFactory
-           implements MenuItemCheckIconFactory {
-        private static final int OFFSET = 3;
-
-        public Icon getIcon(JMenuItem component) {
-            return new VistaMenuItemCheckIcon(component);
-        }
-
-        public boolean isCompatible(Object icon, String prefix) {
-            return icon instanceof VistaMenuItemCheckIcon
-              && ((VistaMenuItemCheckIcon) icon).type == getType(prefix);
-        }
-
-        public Icon getIcon(String type) {
-            return new VistaMenuItemCheckIcon(type);
-        }
-
-        static int getIconWidth() {
-            XPStyle xp = XPStyle.getXP();
-            return ((xp != null) ? xp.getSkin(null, Part.MP_POPUPCHECK).getWidth() : 16)
-                + 2 * OFFSET;
-        }
-
-        private static Class<? extends JMenuItem> getType(Component c) {
-            Class<? extends JMenuItem> rv = null;
-            if (c instanceof JCheckBoxMenuItem) {
-                rv = JCheckBoxMenuItem.class;
-            } else if (c instanceof JRadioButtonMenuItem) {
-                rv = JRadioButtonMenuItem.class;
-            } else if (c instanceof JMenu) {
-                rv = JMenu.class;
-            } else if (c instanceof JMenuItem) {
-                rv = JMenuItem.class;
-            }
-            return rv;
-        }
-
-        private static Class<? extends JMenuItem> getType(String type) {
-            Class<? extends JMenuItem> rv = null;
-            if (type == "CheckBoxMenuItem") {
-                rv = JCheckBoxMenuItem.class;
-            } else if (type == "RadioButtonMenuItem") {
-                rv = JRadioButtonMenuItem.class;
-            } else if (type == "Menu") {
-                rv = JMenu.class;
-            } else if (type == "MenuItem") {
-                rv = JMenuItem.class;
-            } else {
-                // this should never happen
-                rv = JMenuItem.class;
-            }
-            return rv;
-        }
-
-        /**
-         * CheckIcon for JMenuItem, JMenu, JCheckBoxMenuItem and
-         * JRadioButtonMenuItem.
-         * Note: to be used on Vista only.
-         */
-        @SuppressWarnings("serial") // Same-version serialization only
-        private static class VistaMenuItemCheckIcon
-              implements Icon, UIResource, Serializable {
-
-            private final JMenuItem menuItem;
-            private final Class<? extends JMenuItem> type;
-
-            VistaMenuItemCheckIcon(JMenuItem menuItem) {
-                this.type = getType(menuItem);
-                this.menuItem = menuItem;
-            }
-            VistaMenuItemCheckIcon(String type) {
-                this.type = getType(type);
-                this.menuItem = null;
-            }
-
-            public int getIconHeight() {
-                Icon lafIcon = getLaFIcon();
-                if (lafIcon != null) {
-                    return lafIcon.getIconHeight();
-                }
-                Icon icon = getIcon();
-                int height = 0;
-                if (icon != null) {
-                    height = icon.getIconHeight();
-                } else {
-                    XPStyle xp = XPStyle.getXP();
-                    if (xp != null) {
-                        Skin skin = xp.getSkin(null, Part.MP_POPUPCHECK);
-                        height = skin.getHeight();
-                    } else {
-                        height = 16;
-                    }
-                }
-                height +=  2 * OFFSET;
-                return height;
-            }
-
-            public int getIconWidth() {
-                Icon lafIcon = getLaFIcon();
-                if (lafIcon != null) {
-                    return lafIcon.getIconWidth();
-                }
-                Icon icon = getIcon();
-                int width = 0;
-                if (icon != null) {
-                    width = icon.getIconWidth() + 2 * OFFSET;
-                } else {
-                    width = VistaMenuItemCheckIconFactory.getIconWidth();
-                }
-                return width;
-            }
-
-            public void paintIcon(Component c, Graphics g, int x, int y) {
-                Icon lafIcon = getLaFIcon();
-                if (lafIcon != null) {
-                    lafIcon.paintIcon(c, g, x, y);
-                    return;
-                }
-                assert menuItem == null || c == menuItem;
-                Icon icon = getIcon();
-                if (type == JCheckBoxMenuItem.class
-                      || type == JRadioButtonMenuItem.class) {
-                    AbstractButton b = (AbstractButton) c;
-                    if (b.isSelected()) {
-                        Part backgroundPart = Part.MP_POPUPCHECKBACKGROUND;
-                        Part part = Part.MP_POPUPCHECK;
-                        State backgroundState;
-                        State state;
-                        if (isEnabled(c, null)) {
-                            backgroundState =
-                                (icon != null) ? State.BITMAP : State.NORMAL;
-                            state = (type == JRadioButtonMenuItem.class)
-                              ? State.BULLETNORMAL
-                              : State.CHECKMARKNORMAL;
-                        } else {
-                            backgroundState = State.DISABLEDPUSHED;
-                            state =
-                                (type == JRadioButtonMenuItem.class)
-                                  ? State.BULLETDISABLED
-                                  : State.CHECKMARKDISABLED;
-                        }
-                        XPStyle xp = XPStyle.getXP();
-                        if (xp != null) {
-                            Skin skin;
-                            skin =  xp.getSkin(c, backgroundPart);
-                            skin.paintSkin(g, x, y,
-                                getIconWidth(), getIconHeight(), backgroundState);
-                            if (icon == null) {
-                                skin = xp.getSkin(c, part);
-                                skin.paintSkin(g, x + OFFSET, y + OFFSET, state);
-                            }
-                        }
-                    }
-                }
-                if (icon != null) {
-                    icon.paintIcon(c, g, x + OFFSET, y + OFFSET);
-                }
-            }
-            private static WindowsMenuItemUIAccessor getAccessor(
-                    JMenuItem menuItem) {
-                WindowsMenuItemUIAccessor rv = null;
-                ButtonUI uiObject = (menuItem != null) ? menuItem.getUI()
-                        : null;
-                if (uiObject instanceof WindowsMenuItemUI) {
-                    rv = ((WindowsMenuItemUI) uiObject).accessor;
-                } else if (uiObject instanceof WindowsMenuUI) {
-                    rv = ((WindowsMenuUI) uiObject).accessor;
-                } else if (uiObject instanceof WindowsCheckBoxMenuItemUI) {
-                    rv = ((WindowsCheckBoxMenuItemUI) uiObject).accessor;
-                } else if (uiObject instanceof WindowsRadioButtonMenuItemUI) {
-                    rv = ((WindowsRadioButtonMenuItemUI) uiObject).accessor;
-                }
-                return rv;
-            }
-
-            private static boolean isEnabled(Component  c, State state) {
-                if (state == null && c instanceof JMenuItem) {
-                    WindowsMenuItemUIAccessor accessor =
-                        getAccessor((JMenuItem) c);
-                    if (accessor != null) {
-                        state = accessor.getState((JMenuItem) c);
-                    }
-                }
-                if (state == null) {
-                    if (c != null) {
-                        return c.isEnabled();
-                    } else {
-                        return true;
-                    }
-                } else {
-                    return (state != State.DISABLED)
-                        && (state != State.DISABLEDHOT)
-                        && (state != State.DISABLEDPUSHED);
-                }
-            }
-            private Icon getIcon() {
-                Icon rv = null;
-                if (menuItem == null) {
-                    return rv;
-                }
-                WindowsMenuItemUIAccessor accessor =
-                    getAccessor(menuItem);
-                State state = (accessor != null) ? accessor.getState(menuItem)
-                        : null;
-                if (isEnabled(menuItem, null)) {
-                    if (state == State.PUSHED) {
-                        rv = menuItem.getPressedIcon();
-                    } else {
-                        rv = menuItem.getIcon();
-                    }
-                } else {
-                    rv = menuItem.getDisabledIcon();
-                }
-                return rv;
-            }
-            /**
-             * Check if developer changed icon in the UI table.
-             *
-             * @return the icon to use or {@code null} if the current one is to
-             * be used
-             */
-            private Icon getLaFIcon() {
-                // use icon from the UI table if it does not match this one.
-                Icon rv = (Icon) UIManager.getDefaults().get(typeToString(type));
-                if (rv instanceof VistaMenuItemCheckIcon
-                      && ((VistaMenuItemCheckIcon) rv).type == type) {
-                    rv = null;
-                }
-                return rv;
-            }
-
-            private static String typeToString(
-                    Class<? extends JMenuItem> type) {
-                assert type == JMenuItem.class
-                    || type == JMenu.class
-                    || type == JCheckBoxMenuItem.class
-                    || type == JRadioButtonMenuItem.class;
-                StringBuilder sb = new StringBuilder(type.getName());
-                // remove package name, dot and the first character
-                sb.delete(0, sb.lastIndexOf("J") + 1);
-                sb.append(".checkIcon");
-                return sb.toString();
-            }
-        }
-    } // End class VistaMenuItemCheckIconFactory
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsInternalFrameTitlePane.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,572 +0,0 @@
-/*
- * Copyright (c) 2001, 2014, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import sun.swing.SwingUtilities2;
-
-import javax.swing.*;
-import javax.swing.border.*;
-import javax.swing.UIManager;
-import javax.swing.plaf.*;
-import javax.swing.plaf.basic.BasicInternalFrameTitlePane;
-import java.awt.*;
-import java.awt.event.*;
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-import java.beans.PropertyVetoException;
-
-import static com.sun.java.swing.plaf.windows.TMSchema.*;
-import static com.sun.java.swing.plaf.windows.XPStyle.Skin;
-
-@SuppressWarnings("serial") // Superclass is not serializable across versions
-public class WindowsInternalFrameTitlePane extends BasicInternalFrameTitlePane {
-    private Color selectedTitleGradientColor;
-    private Color notSelectedTitleGradientColor;
-    private JPopupMenu systemPopupMenu;
-    private JLabel systemLabel;
-
-    private Font titleFont;
-    private int titlePaneHeight;
-    private int buttonWidth, buttonHeight;
-    private boolean hotTrackingOn;
-
-    public WindowsInternalFrameTitlePane(JInternalFrame f) {
-        super(f);
-    }
-
-    protected void addSubComponents() {
-        add(systemLabel);
-        add(iconButton);
-        add(maxButton);
-        add(closeButton);
-    }
-
-    protected void installDefaults() {
-        super.installDefaults();
-
-        titlePaneHeight = UIManager.getInt("InternalFrame.titlePaneHeight");
-        buttonWidth     = UIManager.getInt("InternalFrame.titleButtonWidth")  - 4;
-        buttonHeight    = UIManager.getInt("InternalFrame.titleButtonHeight") - 4;
-
-        Object obj      = UIManager.get("InternalFrame.titleButtonToolTipsOn");
-        hotTrackingOn = (obj instanceof Boolean) ? (Boolean)obj : true;
-
-
-        if (XPStyle.getXP() != null) {
-            // Fix for XP bug where sometimes these sizes aren't updated properly
-            // Assume for now that height is correct and derive width using the
-            // ratio from the uxtheme part
-            buttonWidth = buttonHeight;
-            Dimension d = XPStyle.getPartSize(Part.WP_CLOSEBUTTON, State.NORMAL);
-            if (d != null && d.width != 0 && d.height != 0) {
-                buttonWidth = (int) ((float) buttonWidth * d.width / d.height);
-            }
-        } else {
-            buttonWidth += 2;
-            Color activeBorderColor =
-                    UIManager.getColor("InternalFrame.activeBorderColor");
-            setBorder(BorderFactory.createLineBorder(activeBorderColor, 1));
-        }
-        // JDK-8039383: initialize these colors because getXP() may return null when theme is changed
-        selectedTitleGradientColor =
-                UIManager.getColor("InternalFrame.activeTitleGradient");
-        notSelectedTitleGradientColor =
-                UIManager.getColor("InternalFrame.inactiveTitleGradient");
-    }
-
-    protected void uninstallListeners() {
-        // Get around protected method in superclass
-        super.uninstallListeners();
-    }
-
-    protected void createButtons() {
-        super.createButtons();
-        if (XPStyle.getXP() != null) {
-            iconButton.setContentAreaFilled(false);
-            maxButton.setContentAreaFilled(false);
-            closeButton.setContentAreaFilled(false);
-        }
-    }
-
-    protected void setButtonIcons() {
-        super.setButtonIcons();
-
-        if (!hotTrackingOn) {
-            iconButton.setToolTipText(null);
-            maxButton.setToolTipText(null);
-            closeButton.setToolTipText(null);
-        }
-    }
-
-
-    public void paintComponent(Graphics g)  {
-        XPStyle xp = XPStyle.getXP();
-
-        paintTitleBackground(g);
-
-        String title = frame.getTitle();
-        if (title != null) {
-            boolean isSelected = frame.isSelected();
-            Font oldFont = g.getFont();
-            Font newFont = (titleFont != null) ? titleFont : getFont();
-            g.setFont(newFont);
-
-            // Center text vertically.
-            FontMetrics fm = SwingUtilities2.getFontMetrics(frame, g, newFont);
-            int baseline = (getHeight() + fm.getAscent() - fm.getLeading() -
-                    fm.getDescent()) / 2;
-
-            Rectangle lastIconBounds = new Rectangle(0, 0, 0, 0);
-            if (frame.isIconifiable()) {
-                lastIconBounds = iconButton.getBounds();
-            } else if (frame.isMaximizable()) {
-                lastIconBounds = maxButton.getBounds();
-            } else if (frame.isClosable()) {
-                lastIconBounds = closeButton.getBounds();
-            }
-
-            int titleX;
-            int titleW;
-            int gap = 2;
-            if (WindowsGraphicsUtils.isLeftToRight(frame)) {
-                if (lastIconBounds.x == 0) { // There are no icons
-                    lastIconBounds.x = frame.getWidth() - frame.getInsets().right;
-                }
-                titleX = systemLabel.getX() + systemLabel.getWidth() + gap;
-                if (xp != null) {
-                    titleX += 2;
-                }
-                titleW = lastIconBounds.x - titleX - gap;
-            } else {
-                if (lastIconBounds.x == 0) { // There are no icons
-                    lastIconBounds.x = frame.getInsets().left;
-                }
-                titleW = SwingUtilities2.stringWidth(frame, fm, title);
-                int minTitleX = lastIconBounds.x + lastIconBounds.width + gap;
-                if (xp != null) {
-                    minTitleX += 2;
-                }
-                int availableWidth = systemLabel.getX() - gap - minTitleX;
-                if (availableWidth > titleW) {
-                    titleX = systemLabel.getX() - gap - titleW;
-                } else {
-                    titleX = minTitleX;
-                    titleW = availableWidth;
-                }
-            }
-            title = getTitle(frame.getTitle(), fm, titleW);
-
-            if (xp != null) {
-                String shadowType = null;
-                if (isSelected) {
-                    shadowType = xp.getString(this, Part.WP_CAPTION,
-                                              State.ACTIVE, Prop.TEXTSHADOWTYPE);
-                }
-                if ("single".equalsIgnoreCase(shadowType)) {
-                    Point shadowOffset = xp.getPoint(this, Part.WP_WINDOW, State.ACTIVE,
-                                                     Prop.TEXTSHADOWOFFSET);
-                    Color shadowColor  = xp.getColor(this, Part.WP_WINDOW, State.ACTIVE,
-                                                     Prop.TEXTSHADOWCOLOR, null);
-                    if (shadowOffset != null && shadowColor != null) {
-                        g.setColor(shadowColor);
-                        SwingUtilities2.drawString(frame, g, title,
-                                     titleX + shadowOffset.x,
-                                     baseline + shadowOffset.y);
-                    }
-                }
-            }
-            g.setColor(isSelected ? selectedTextColor : notSelectedTextColor);
-            SwingUtilities2.drawString(frame, g, title, titleX, baseline);
-            g.setFont(oldFont);
-        }
-    }
-
-    public Dimension getPreferredSize() {
-        return getMinimumSize();
-    }
-
-    public Dimension getMinimumSize() {
-        Dimension d = new Dimension(super.getMinimumSize());
-        d.height = titlePaneHeight + 2;
-
-        XPStyle xp = XPStyle.getXP();
-        if (xp != null) {
-            // Note: Don't know how to calculate height on XP,
-            // the captionbarheight is 25 but native caption is 30 (maximized 26)
-            if (frame.isMaximum()) {
-                d.height -= 1;
-            } else {
-                d.height += 3;
-            }
-        }
-        return d;
-    }
-
-    protected void paintTitleBackground(Graphics g) {
-        XPStyle xp = XPStyle.getXP();
-        if (xp != null) {
-            Part part = frame.isIcon() ? Part.WP_MINCAPTION
-                                       : (frame.isMaximum() ? Part.WP_MAXCAPTION
-                                                            : Part.WP_CAPTION);
-            State state = frame.isSelected() ? State.ACTIVE : State.INACTIVE;
-            Skin skin = xp.getSkin(this, part);
-            skin.paintSkin(g, 0,  0, getWidth(), getHeight(), state);
-        } else {
-            Boolean gradientsOn = (Boolean)LookAndFeel.getDesktopPropertyValue(
-                "win.frame.captionGradientsOn", Boolean.valueOf(false));
-            if (gradientsOn.booleanValue() && g instanceof Graphics2D) {
-                Graphics2D g2 = (Graphics2D)g;
-                Paint savePaint = g2.getPaint();
-
-                boolean isSelected = frame.isSelected();
-                int w = getWidth();
-
-                if (isSelected) {
-                    GradientPaint titleGradient = new GradientPaint(0,0,
-                            selectedTitleColor,
-                            (int)(w*.75),0,
-                            selectedTitleGradientColor);
-                    g2.setPaint(titleGradient);
-                } else {
-                    GradientPaint titleGradient = new GradientPaint(0,0,
-                            notSelectedTitleColor,
-                            (int)(w*.75),0,
-                            notSelectedTitleGradientColor);
-                    g2.setPaint(titleGradient);
-                }
-                g2.fillRect(0, 0, getWidth(), getHeight());
-                g2.setPaint(savePaint);
-            } else {
-                super.paintTitleBackground(g);
-            }
-        }
-    }
-
-    protected void assembleSystemMenu() {
-        systemPopupMenu = new JPopupMenu();
-        addSystemMenuItems(systemPopupMenu);
-        enableActions();
-        @SuppressWarnings("serial") // anonymous class
-        JLabel tmp = new JLabel(frame.getFrameIcon()) {
-            protected void paintComponent(Graphics g) {
-                int x = 0;
-                int y = 0;
-                int w = getWidth();
-                int h = getHeight();
-                g = g.create();  // Create scratch graphics
-                if (isOpaque()) {
-                    g.setColor(getBackground());
-                    g.fillRect(0, 0, w, h);
-                }
-                Icon icon = getIcon();
-                int iconWidth;
-                int iconHeight;
-                if (icon != null &&
-                    (iconWidth = icon.getIconWidth()) > 0 &&
-                    (iconHeight = icon.getIconHeight()) > 0) {
-
-                    // Set drawing scale to make icon scale to our desired size
-                    double drawScale;
-                    if (iconWidth > iconHeight) {
-                        // Center icon vertically
-                        y = (h - w*iconHeight/iconWidth) / 2;
-                        drawScale = w / (double)iconWidth;
-                    } else {
-                        // Center icon horizontally
-                        x = (w - h*iconWidth/iconHeight) / 2;
-                        drawScale = h / (double)iconHeight;
-                    }
-                    ((Graphics2D)g).translate(x, y);
-                    ((Graphics2D)g).scale(drawScale, drawScale);
-                    icon.paintIcon(this, g, 0, 0);
-                }
-                g.dispose();
-            }
-        };
-        systemLabel = tmp;
-        systemLabel.addMouseListener(new MouseAdapter() {
-            public void mouseClicked(MouseEvent e) {
-                if (e.getClickCount() == 2 && frame.isClosable() &&
-                    !frame.isIcon()) {
-                    systemPopupMenu.setVisible(false);
-                    frame.doDefaultCloseAction();
-                }
-                else {
-                    super.mouseClicked(e);
-                }
-            }
-            public void mousePressed(MouseEvent e) {
-                try {
-                    frame.setSelected(true);
-                } catch(PropertyVetoException pve) {
-                }
-                showSystemPopupMenu(e.getComponent());
-            }
-        });
-    }
-
-    protected void addSystemMenuItems(JPopupMenu menu) {
-        JMenuItem mi = menu.add(restoreAction);
-        mi.setMnemonic(getButtonMnemonic("restore"));
-        mi = menu.add(moveAction);
-        mi.setMnemonic(getButtonMnemonic("move"));
-        mi = menu.add(sizeAction);
-        mi.setMnemonic(getButtonMnemonic("size"));
-        mi = menu.add(iconifyAction);
-        mi.setMnemonic(getButtonMnemonic("minimize"));
-        mi = menu.add(maximizeAction);
-        mi.setMnemonic(getButtonMnemonic("maximize"));
-        menu.add(new JSeparator());
-        mi = menu.add(closeAction);
-        mi.setMnemonic(getButtonMnemonic("close"));
-    }
-
-    private static int getButtonMnemonic(String button) {
-        try {
-            return Integer.parseInt(UIManager.getString(
-                    "InternalFrameTitlePane." + button + "Button.mnemonic"));
-        } catch (NumberFormatException e) {
-            return -1;
-        }
-    }
-
-    protected void showSystemMenu(){
-        showSystemPopupMenu(systemLabel);
-    }
-
-    private void showSystemPopupMenu(Component invoker){
-        Dimension dim = new Dimension();
-        Border border = frame.getBorder();
-        if (border != null) {
-            dim.width += border.getBorderInsets(frame).left +
-                border.getBorderInsets(frame).right;
-            dim.height += border.getBorderInsets(frame).bottom +
-                border.getBorderInsets(frame).top;
-        }
-        if (!frame.isIcon()) {
-            systemPopupMenu.show(invoker,
-                getX() - dim.width,
-                getY() + getHeight() - dim.height);
-        } else {
-            systemPopupMenu.show(invoker,
-                getX() - dim.width,
-                getY() - systemPopupMenu.getPreferredSize().height -
-                     dim.height);
-        }
-    }
-
-    protected PropertyChangeListener createPropertyChangeListener() {
-        return new WindowsPropertyChangeHandler();
-    }
-
-    protected LayoutManager createLayout() {
-        return new WindowsTitlePaneLayout();
-    }
-
-    public class WindowsTitlePaneLayout extends BasicInternalFrameTitlePane.TitlePaneLayout {
-        private Insets captionMargin = null;
-        private Insets contentMargin = null;
-        private XPStyle xp = XPStyle.getXP();
-
-        WindowsTitlePaneLayout() {
-            if (xp != null) {
-                Component c = WindowsInternalFrameTitlePane.this;
-                captionMargin = xp.getMargin(c, Part.WP_CAPTION, null, Prop.CAPTIONMARGINS);
-                contentMargin = xp.getMargin(c, Part.WP_CAPTION, null, Prop.CONTENTMARGINS);
-            }
-            if (captionMargin == null) {
-                captionMargin = new Insets(0, 2, 0, 2);
-            }
-            if (contentMargin == null) {
-                contentMargin = new Insets(0, 0, 0, 0);
-            }
-        }
-
-        private int layoutButton(JComponent button, Part part,
-                                 int x, int y, int w, int h, int gap,
-                                 boolean leftToRight) {
-            if (!leftToRight) {
-                x -= w;
-            }
-            button.setBounds(x, y, w, h);
-            if (leftToRight) {
-                x += w + 2;
-            } else {
-                x -= 2;
-            }
-            return x;
-        }
-
-        public void layoutContainer(Container c) {
-            boolean leftToRight = WindowsGraphicsUtils.isLeftToRight(frame);
-            int x, y;
-            int w = getWidth();
-            int h = getHeight();
-
-            // System button
-            // Note: this icon is square, but the buttons aren't always.
-            int iconSize = (xp != null) ? (h-2)*6/10 : h-4;
-            if (xp != null) {
-                x = (leftToRight) ? captionMargin.left + 2 : w - captionMargin.right - 2;
-            } else {
-                x = (leftToRight) ? captionMargin.left : w - captionMargin.right;
-            }
-            y = (h - iconSize) / 2;
-            layoutButton(systemLabel, Part.WP_SYSBUTTON,
-                         x, y, iconSize, iconSize, 0,
-                         leftToRight);
-
-            // Right hand buttons
-            if (xp != null) {
-                x = (leftToRight) ? w - captionMargin.right - 2 : captionMargin.left + 2;
-                y = 1;  // XP seems to ignore margins and offset here
-                if (frame.isMaximum()) {
-                    y += 1;
-                } else {
-                    y += 5;
-                }
-            } else {
-                x = (leftToRight) ? w - captionMargin.right : captionMargin.left;
-                y = (h - buttonHeight) / 2;
-            }
-
-            if(frame.isClosable()) {
-                x = layoutButton(closeButton, Part.WP_CLOSEBUTTON,
-                                 x, y, buttonWidth, buttonHeight, 2,
-                                 !leftToRight);
-            }
-
-            if(frame.isMaximizable()) {
-                x = layoutButton(maxButton, Part.WP_MAXBUTTON,
-                                 x, y, buttonWidth, buttonHeight, (xp != null) ? 2 : 0,
-                                 !leftToRight);
-            }
-
-            if(frame.isIconifiable()) {
-                layoutButton(iconButton, Part.WP_MINBUTTON,
-                             x, y, buttonWidth, buttonHeight, 0,
-                             !leftToRight);
-            }
-        }
-    } // end WindowsTitlePaneLayout
-
-    public class WindowsPropertyChangeHandler extends PropertyChangeHandler {
-        public void propertyChange(PropertyChangeEvent evt) {
-            String prop = evt.getPropertyName();
-
-            // Update the internal frame icon for the system menu.
-            if (JInternalFrame.FRAME_ICON_PROPERTY.equals(prop) &&
-                    systemLabel != null) {
-                systemLabel.setIcon(frame.getFrameIcon());
-            }
-
-            super.propertyChange(evt);
-        }
-    }
-
-    /**
-     * A versatile Icon implementation which can take an array of Icon
-     * instances (typically <code>ImageIcon</code>s) and choose one that gives the best
-     * quality for a given Graphics2D scale factor when painting.
-     * <p>
-     * The class is public so it can be instantiated by UIDefaults.ProxyLazyValue.
-     * <p>
-     * Note: We assume here that icons are square.
-     */
-    public static class ScalableIconUIResource implements Icon, UIResource {
-        // We can use an arbitrary size here because we scale to it in paintIcon()
-        private static final int SIZE = 16;
-
-        private Icon[] icons;
-
-        /**
-         * @param objects an array of Icon or UIDefaults.LazyValue
-         * <p>
-         * The constructor is public so it can be called by UIDefaults.ProxyLazyValue.
-         */
-        public ScalableIconUIResource(Object[] objects) {
-            this.icons = new Icon[objects.length];
-
-            for (int i = 0; i < objects.length; i++) {
-                if (objects[i] instanceof UIDefaults.LazyValue) {
-                    icons[i] = (Icon)((UIDefaults.LazyValue)objects[i]).createValue(null);
-                } else {
-                    icons[i] = (Icon)objects[i];
-                }
-            }
-        }
-
-        /**
-         * @return the <code>Icon</code> closest to the requested size
-         */
-        protected Icon getBestIcon(int size) {
-            if (icons != null && icons.length > 0) {
-                int bestIndex = 0;
-                int minDiff = Integer.MAX_VALUE;
-                for (int i=0; i < icons.length; i++) {
-                    Icon icon = icons[i];
-                    int iconSize;
-                    if (icon != null && (iconSize = icon.getIconWidth()) > 0) {
-                        int diff = Math.abs(iconSize - size);
-                        if (diff < minDiff) {
-                            minDiff = diff;
-                            bestIndex = i;
-                        }
-                    }
-                }
-                return icons[bestIndex];
-            } else {
-                return null;
-            }
-        }
-
-        public void paintIcon(Component c, Graphics g, int x, int y) {
-            Graphics2D g2d = (Graphics2D)g.create();
-            // Calculate how big our drawing area is in pixels
-            // Assume we are square
-            int size = getIconWidth();
-            double scale = g2d.getTransform().getScaleX();
-            Icon icon = getBestIcon((int)(size * scale));
-            int iconSize;
-            if (icon != null && (iconSize = icon.getIconWidth()) > 0) {
-                // Set drawing scale to make icon act true to our reported size
-                double drawScale = size / (double)iconSize;
-                g2d.translate(x, y);
-                g2d.scale(drawScale, drawScale);
-                icon.paintIcon(c, g2d, 0, 0);
-            }
-            g2d.dispose();
-        }
-
-        public int getIconWidth() {
-            return SIZE;
-        }
-
-        public int getIconHeight() {
-            return SIZE;
-        }
-    }
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsInternalFrameUI.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,135 +0,0 @@
-/*
- * Copyright (c) 1997, 2014, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import java.awt.*;
-import java.beans.*;
-import javax.swing.*;
-import javax.swing.border.*;
-import javax.swing.plaf.basic.*;
-import javax.swing.plaf.ComponentUI;
-
-import static com.sun.java.swing.plaf.windows.TMSchema.*;
-import static com.sun.java.swing.plaf.windows.XPStyle.Skin;
-
-/**
- * Windows rendition of the component.
- * <p>
- * <strong>Warning:</strong>
- * Serialized objects of this class will not be compatible with
- * future Swing releases.  The current serialization support is appropriate
- * for short term storage or RMI between applications running the same
- * version of Swing.  A future release of Swing will provide support for
- * long term persistence.
- */
-public class WindowsInternalFrameUI extends BasicInternalFrameUI
-{
-    XPStyle xp = XPStyle.getXP();
-
-    public void installDefaults() {
-        super.installDefaults();
-
-        if (xp != null) {
-            frame.setBorder(new XPBorder());
-        } else {
-            frame.setBorder(UIManager.getBorder("InternalFrame.border"));
-        }
-    }
-
-    public void installUI(JComponent c)   {
-        super.installUI(c);
-
-        LookAndFeel.installProperty(c, "opaque",
-                                    xp == null? Boolean.TRUE : Boolean.FALSE);
-    }
-
-    public void uninstallDefaults() {
-        frame.setBorder(null);
-        super.uninstallDefaults();
-    }
-
-    public static ComponentUI createUI(JComponent b)    {
-        return new WindowsInternalFrameUI((JInternalFrame)b);
-    }
-
-    public WindowsInternalFrameUI(JInternalFrame w){
-        super(w);
-    }
-
-    protected DesktopManager createDesktopManager(){
-        return new WindowsDesktopManager();
-    }
-
-    protected JComponent createNorthPane(JInternalFrame w) {
-        titlePane = new WindowsInternalFrameTitlePane(w);
-        return titlePane;
-    }
-
-    @SuppressWarnings("serial") // Superclass is not serializable across versions
-    private class XPBorder extends AbstractBorder {
-        private Skin leftSkin   = xp.getSkin(frame, Part.WP_FRAMELEFT);
-        private Skin rightSkin  = xp.getSkin(frame, Part.WP_FRAMERIGHT);
-        private Skin bottomSkin = xp.getSkin(frame, Part.WP_FRAMEBOTTOM);
-
-        /**
-         * @param x the x position of the painted border
-         * @param y the y position of the painted border
-         * @param width the width of the painted border
-         * @param height the height of the painted border
-         */
-        public void paintBorder(Component c, Graphics g, int x, int y, int width, int height) {
-            State state = ((JInternalFrame)c).isSelected() ? State.ACTIVE : State.INACTIVE;
-            int topBorderHeight  = (titlePane != null) ? titlePane.getSize().height : 0;
-
-            bottomSkin.paintSkin(g, 0, height-bottomSkin.getHeight(),
-                                 width, bottomSkin.getHeight(),
-                                 state);
-
-            leftSkin.paintSkin(g, 0, topBorderHeight-1,
-                               leftSkin.getWidth(), height-topBorderHeight-bottomSkin.getHeight()+2,
-                               state);
-
-            rightSkin.paintSkin(g, width-rightSkin.getWidth(), topBorderHeight-1,
-                                rightSkin.getWidth(), height-topBorderHeight-bottomSkin.getHeight()+2,
-                                state);
-
-        }
-
-        public Insets getBorderInsets(Component c, Insets insets) {
-            insets.top    = 4;
-            insets.left   = leftSkin.getWidth();
-            insets.right  = rightSkin.getWidth();
-            insets.bottom = bottomSkin.getHeight();
-
-            return insets;
-        }
-
-        public boolean isBorderOpaque() {
-            return true;
-        }
-    }
-
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsLabelUI.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,112 +0,0 @@
-/*
- * Copyright (c) 1997, 2005, 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.
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import sun.swing.SwingUtilities2;
-import sun.awt.AppContext;
-
-import java.awt.Color;
-import java.awt.Graphics;
-
-import javax.swing.JComponent;
-import javax.swing.JLabel;
-import javax.swing.UIManager;
-
-import javax.swing.plaf.ComponentUI;
-
-import javax.swing.plaf.basic.BasicLabelUI;
-
-
-
-/**
- * Windows rendition of the component.
- * <p>
- * <strong>Warning:</strong>
- * Serialized objects of this class will not be compatible with
- * future Swing releases.  The current serialization support is appropriate
- * for short term storage or RMI between applications running the same
- * version of Swing.  A future release of Swing will provide support for
- * long term persistence.
- */
-public class WindowsLabelUI extends BasicLabelUI {
-
-    private static final Object WINDOWS_LABEL_UI_KEY = new Object();
-
-    // ********************************
-    //          Create PLAF
-    // ********************************
-    public static ComponentUI createUI(JComponent c) {
-        AppContext appContext = AppContext.getAppContext();
-        WindowsLabelUI windowsLabelUI =
-                (WindowsLabelUI) appContext.get(WINDOWS_LABEL_UI_KEY);
-        if (windowsLabelUI == null) {
-            windowsLabelUI = new WindowsLabelUI();
-            appContext.put(WINDOWS_LABEL_UI_KEY, windowsLabelUI);
-        }
-        return windowsLabelUI;
-    }
-
-    protected void paintEnabledText(JLabel l, Graphics g, String s,
-                                    int textX, int textY) {
-        int mnemonicIndex = l.getDisplayedMnemonicIndex();
-        // W2K Feature: Check to see if the Underscore should be rendered.
-        if (WindowsLookAndFeel.isMnemonicHidden() == true) {
-            mnemonicIndex = -1;
-        }
-
-        g.setColor(l.getForeground());
-        SwingUtilities2.drawStringUnderlineCharAt(l, g, s, mnemonicIndex,
-                                                     textX, textY);
-    }
-
-    protected void paintDisabledText(JLabel l, Graphics g, String s,
-                                     int textX, int textY) {
-        int mnemonicIndex = l.getDisplayedMnemonicIndex();
-        // W2K Feature: Check to see if the Underscore should be rendered.
-        if (WindowsLookAndFeel.isMnemonicHidden() == true) {
-            mnemonicIndex = -1;
-        }
-        if ( UIManager.getColor("Label.disabledForeground") instanceof Color &&
-             UIManager.getColor("Label.disabledShadow") instanceof Color) {
-            g.setColor( UIManager.getColor("Label.disabledShadow") );
-            SwingUtilities2.drawStringUnderlineCharAt(l, g, s,
-                                                         mnemonicIndex,
-                                                         textX + 1, textY + 1);
-            g.setColor( UIManager.getColor("Label.disabledForeground") );
-            SwingUtilities2.drawStringUnderlineCharAt(l, g, s,
-                                                         mnemonicIndex,
-                                                         textX, textY);
-        } else {
-            Color background = l.getBackground();
-            g.setColor(background.brighter());
-            SwingUtilities2.drawStringUnderlineCharAt(l,g, s, mnemonicIndex,
-                                                         textX + 1, textY + 1);
-            g.setColor(background.darker());
-            SwingUtilities2.drawStringUnderlineCharAt(l,g, s, mnemonicIndex,
-                                                         textX, textY);
-        }
-    }
-}
--- a/src/java.desktop/share/classes/com/sun/java/swing/plaf/windows/WindowsLookAndFeel.java	Mon Dec 04 10:12:46 2017 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,2588 +0,0 @@
-/*
- * Copyright (c) 1997, 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.
- */
-
-/*
- * <p>These classes are designed to be used while the
- * corresponding <code>LookAndFeel</code> class has been installed
- * (<code>UIManager.setLookAndFeel(new <i>XXX</i>LookAndFeel())</code>).
- * Using them while a different <code>LookAndFeel</code> is installed
- * may produce unexpected results, including exceptions.
- * Additionally, changing the <code>LookAndFeel</code>
- * maintained by the <code>UIManager</code> without updating the
- * corresponding <code>ComponentUI</code> of any
- * <code>JComponent</code>s may also produce unexpected results,
- * such as the wrong colors showing up, and is generally not
- * encouraged.
- *
- */
-
-package com.sun.java.swing.plaf.windows;
-
-import java.awt.*;
-import java.awt.image.BufferedImage;
-import java.awt.image.ImageFilter;
-import java.awt.image.ImageProducer;
-import java.awt.image.FilteredImageSource;
-import java.awt.image.RGBImageFilter;
-
-import javax.swing.plaf.*;
-import javax.swing.*;
-import javax.swing.plaf.basic.*;
-import javax.swing.border.*;
-import javax.swing.text.DefaultEditorKit;
-import static javax.swing.UIDefaults.LazyValue;
-
-import java.awt.Font;
-import java.awt.Color;
-import java.awt.event.ActionEvent;
-
-import java.security.AccessController;
-
-import sun.awt.SunToolkit;
-import sun.awt.OSInfo;
-import sun.awt.shell.ShellFolder;
-import sun.font.FontUtilities;
-import sun.security.action.GetPropertyAction;
-
-import sun.swing.DefaultLayoutStyle;
-import sun.swing.ImageIconUIResource;
-import sun.swing.SwingAccessor;
-import sun.swing.icon.SortArrowIcon;
-import sun.swing.SwingUtilities2;
-import sun.swing.StringUIClientPropertyKey;
-import sun.swing.plaf.windows.ClassicSortArrowIcon;
-
-import static com.sun.java.swing.plaf.windows.TMSchema.*;
-import static com.sun.java.swing.plaf.windows.XPStyle.Skin;
-
-import com.sun.java.swing.plaf.windows.WindowsIconFactory.VistaMenuItemCheckIconFactory;
-
-/**
- * Implements the Windows95/98/NT/2000 Look and Feel.
- * UI classes not implemented specifically for Windows will
- * default to those implemented in Basic.
- * <p>
- * <strong>Warning:</strong>
- * Serialized objects of this class will not be compatible with
- * future Swing releases.  The current serialization support is appropriate
- * for short term storage or RMI between applications running the same
- * version of Swing.  A future release of Swing will provide support for
- * long term persistence.
- *
- * @author unattributed
- */
-@SuppressWarnings("serial") // Superclass is not serializable across versions
-public class WindowsLookAndFeel extends BasicLookAndFeel
-{
-    /**
-     * A client property that can be used with any JComponent that will end up
-     * calling the LookAndFeel.getDisabledIcon method. This client property,
-     * when set to Boolean.TRUE, will cause getDisabledIcon to use an
-     * alternate algorithm for creating disabled icons to produce icons
-     * that appear similar to the native Windows file chooser
-     */
-    static final Object HI_RES_DISABLED_ICON_CLIENT_KEY =
-        new StringUIClientPropertyKey(
-            "WindowsLookAndFeel.generateHiResDisabledIcon");
-
-    private boolean updatePending = false;
-
-    private boolean useSystemFontSettings = true;
-    private boolean useSystemFontSizeSettings;
-
-    // These properties are not used directly, but are kept as
-    // private members to avoid being GC'd.
-    private WindowsDesktopProperty themeActive, dllName, colorName, sizeName;
-    private WindowsDesktopProperty aaSettings;
-
-    private transient LayoutStyle style;
-
-    /**
-     * Base dialog units along the horizontal axis.
-     */
-    private int baseUnitX;
-
-    /**
-     * Base dialog units along the vertical axis.
-     */
-    private int baseUnitY;
-
-    public String getName() {
-        return "Windows";
-    }
-
-    public String getDescription() {
-        return "The Microsoft Windows Look and Feel";
-    }
-
-    public String getID() {
-        return "Windows";
-    }
-
-    public boolean isNativeLookAndFeel() {
-        return OSInfo.getOSType() == OSInfo.OSType.WINDOWS;
-    }
-
-    public boolean isSupportedLookAndFeel() {
-        return isNativeLookAndFeel();
-    }
-
-    public void initialize() {
-        super.initialize();
-
-        // Set the flag which determines which version of Windows should
-        // be rendered. This flag only need to be set once.
-        // if version <= 4.0 then the classic LAF should be loaded.
-        if (OSInfo.getWindowsVersion().compareTo(OSInfo.WINDOWS_95) <= 0) {
-            isClassicWindows = true;
-        } else {
-            isClassicWindows = false;
-            XPStyle.invalidateStyle();
-        }
-
-        // Using the fonts set by the user can potentially cause
-        // performance and compatibility issues, so allow this feature
-        // to be switched off either at runtime or programmatically
-        //
-        String systemFonts = java.security.AccessController.doPrivileged(
-               new GetPropertyAction("swing.useSystemFontSettings"));
-        useSystemFontSettings = (systemFonts == null ||
-                                 Boolean.valueOf(systemFonts).booleanValue());
-
-        if (useSystemFontSettings) {
-            Object value = UIManager.get("Application.useSystemFontSettings");
-
-            useSystemFontSettings = (value == null ||
-                                     Boolean.TRUE.equals(value));
-        }
-        KeyboardFocusManager.getCurrentKeyboardFocusManager().
-            addKeyEventPostProcessor(WindowsRootPaneUI.altProcessor);
-
-    }
-
-    /**
-     * Initialize the uiClassID to BasicComponentUI mapping.
-     * The JComponent classes define their own uiClassID constants
-     * (see AbstractComponent.getUIClassID).  This table must
-     * map those constants to a BasicComponentUI class of the
-     * appropriate type.
-     *
-     * @see BasicLookAndFeel#getDefaults
-     */
-    protected void initClassDefaults(UIDefaults table)
-    {
-        super.initClassDefaults(table);
-
-        final String windowsPackageName = "com.sun.java.swing.plaf.windows.";
-
-        Object[] uiDefaults = {
-              "ButtonUI", windowsPackageName + "WindowsButtonUI",
-            "CheckBoxUI", windowsPackageName + "WindowsCheckBoxUI",
-    "CheckBoxMenuItemUI", windowsPackageName + "WindowsCheckBoxMenuItemUI",
-               "LabelUI", windowsPackageName + "WindowsLabelUI",
-         "RadioButtonUI", windowsPackageName + "WindowsRadioButtonUI",
- "RadioButtonMenuItemUI", windowsPackageName + "WindowsRadioButtonMenuItemUI",
-        "ToggleButtonUI", windowsPackageName + "WindowsToggleButtonUI",
-         "ProgressBarUI", windowsPackageName + "WindowsProgressBarUI",
-              "SliderUI", windowsPackageName + "WindowsSliderUI",
-           "SeparatorUI", windowsPackageName + "WindowsSeparatorUI",
-           "SplitPaneUI", windowsPackageName + "WindowsSplitPaneUI",
-             "SpinnerUI", windowsPackageName + "WindowsSpinnerUI",
-          "TabbedPaneUI", windowsPackageName + "WindowsTabbedPaneUI",
-            "TextAreaUI", windowsPackageName + "WindowsTextAreaUI",
-           "TextFieldUI", windowsPackageName + "WindowsTextFieldUI",
-       "PasswordFieldUI", windowsPackageName + "WindowsPasswordFieldUI",
-            "TextPaneUI", windowsPackageName + "WindowsTextPaneUI",
-          "EditorPaneUI", windowsPackageName + "WindowsEditorPaneUI",
-                "TreeUI", windowsPackageName + "WindowsTreeUI",
-             "ToolBarUI", windowsPackageName + "WindowsToolBarUI",
-    "ToolBarSeparatorUI", windowsPackageName + "WindowsToolBarSeparatorUI",
-            "ComboBoxUI", windowsPackageName + "WindowsComboBoxUI",
-         "TableHeaderUI", windowsPackageName + "WindowsTableHeaderUI",
-       "InternalFrameUI", windowsPackageName + "WindowsInternalFrameUI",
-         "DesktopPaneUI", windowsPackageName + "WindowsDesktopPaneUI",
-         "DesktopIconUI", windowsPackageName + "WindowsDesktopIconUI",
-         "FileChooserUI", windowsPackageName + "WindowsFileChooserUI",
-                "MenuUI", windowsPackageName + "WindowsMenuUI",
-            "MenuItemUI", windowsPackageName + "WindowsMenuItemUI",
-             "MenuBarUI", windowsPackageName + "WindowsMenuBarUI",
-           "PopupMenuUI", windowsPackageName + "WindowsPopupMenuUI",
-  "PopupMenuSeparatorUI", windowsPackageName + "WindowsPopupMenuSeparatorUI",
-           "ScrollBarUI", windowsPackageName + "WindowsScrollBarUI",
-            "RootPaneUI", windowsPackageName + "WindowsRootPaneUI"
-        };
-
-        table.putDefaults(uiDefaults);
-    }
-
-    /**
-     * Load the SystemColors into the defaults table.  The keys
-     * for SystemColor defaults are the same as the names of
-     * the public fields in SystemColor.  If the table is being
-     * created on a native Windows platform we use the SystemColor
-     * values, otherwise we create color objects whose values match
-     * the defaults Windows95 colors.
-     */
-    protected void initSystemColorDefaults(UIDefaults table)
-    {
-        String[] defaultSystemColors = {
-                "desktop", "#005C5C", /* Color of the desktop background */
-          "activeCaption", "#000080", /* Color for captions (title bars) when they are active. */
-      "activeCaptionText", "#FFFFFF", /* Text color for text in captions (title bars). */
-    "activeCaptionBorder", "#C0C0C0", /* Border color for caption (title bar) window borders. */
-        "inactiveCaption", "#808080", /* Color for captions (title bars) when not active. */
-    "inactiveCaptionText", "#C0C0C0", /* Text color for text in inactive captions (title bars). */
-  "inactiveCaptionBorder", "#C0C0C0", /* Border color for inactive caption (title bar) window borders. */
-                 "window", "#FFFFFF", /* Default color for the interior of windows */
-           "windowBorder", "#000000", /* ??? */
-             "windowText", "#000000", /* ??? */
-                   "menu", "#C0C0C0", /* Background color for menus */
-       "menuPressedItemB", "#000080", /* LightShadow of menubutton highlight */
-       "menuPressedItemF", "#FFFFFF", /* Default color for foreground "text" in menu item */
-               "menuText", "#000000", /* Text color for menus  */
-                   "text", "#C0C0C0", /* Text background color */
-               "textText", "#000000", /* Text foreground color */
-          "textHighlight", "#000080", /* Text background color when selected */
-      "textHighlightText", "#FFFFFF", /* Text color when selected */
-       "textInactiveText", "#808080", /* Text color when disabled */
-                "control", "#C0C0C0", /* Default color for controls (buttons, sliders, etc) */
-            "controlText", "#000000", /* Default color for text in controls */
-       "controlHighlight", "#C0C0C0",
-
-  /*"controlHighlight", "#E0E0E0",*/ /* Specular highlight (opposite of the shadow) */
-     "controlLtHighlight", "#FFFFFF", /* Highlight color for controls */
-          "controlShadow", "#808080", /* Shadow color for controls */
-        "controlDkShadow", "#000000", /* Dark shadow color for controls */
-              "scrollbar", "#E0E0E0", /* Scrollbar background (usually the "track") */
-                   "info", "#FFFFE1", /* ??? */
-               "infoText", "#000000"  /* ??? */
-        };
-
-        loadSystemColors(table, defaultSystemColors, isNativeLookAndFeel());
-    }
-
-   /**
-     * Initialize the defaults table with the name of the ResourceBundle
-     * used for getting localized defaults.
-     */
-    private void initResourceBundle(UIDefaults table) {
-        SwingAccessor.getUIDefaultsAccessor()
-                     .addInternalBundle(table,
-                             "com.sun.java.swing.plaf.windows.resources.windows");
-    }
-
-    // XXX - there are probably a lot of redundant values that could be removed.
-    // ie. Take a look at RadioButtonBorder, etc...
-    protected void initComponentDefaults(UIDefaults table)
-    {
-        super.initComponentDefaults( table );
-
-        initResourceBundle(table);
-
-        // *** Shared Fonts
-        LazyValue dialogPlain12 = t -> new FontUIResource(Font.DIALOG, Font.PLAIN, 12);
-
-        LazyValue sansSerifPlain12 =  t -> new FontUIResource(Font.SANS_SERIF, Font.PLAIN, 12);
-        LazyValue monospacedPlain12 = t -> new FontUIResource(Font.MONOSPACED, Font.PLAIN, 12);
-        LazyValue dialogBold12 = t -> new FontUIResource(Font.DIALOG, Font.BOLD, 12);
-
-        // *** Colors
-        // XXX - some of these doens't seem to be used
-        ColorUIResource red = new ColorUIResource(Color.red);
-        ColorUIResource black = new ColorUIResource(Color.black);
-        ColorUIResource white = new ColorUIResource(Color.white);
-        ColorUIResource gray = new ColorUIResource(Color.gray);
-        ColorUIResource darkGray = new ColorUIResource(Color.darkGray);
-        ColorUIResource scrollBarTrackHighlight = darkGray;
-
-        // Set the flag which determines which version of Windows should
-        // be rendered. This flag only need to be set once.
-        // if version <= 4.0 then the classic LAF should be loaded.
-        isClassicWindows = OSInfo.getWindowsVersion().compareTo(OSInfo.WINDOWS_95) <= 0;
-
-        // *** Tree
-        Object treeExpandedIcon = WindowsTreeUI.ExpandedIcon.createExpandedIcon();
-
-        Object treeCollapsedIcon = WindowsTreeUI.CollapsedIcon.createCollapsedIcon();
-
-
-        // *** Text
-        Object fieldInputMap = new UIDefaults.LazyInputMap(new Object[] {
-                      "control C", DefaultEditorKit.copyAction,
-                      "control V", DefaultEditorKit.pasteAction,
-                      "control X", DefaultEditorKit.cutAction,
-                           "COPY", DefaultEditorKit.copyAction,
-                          "PASTE", DefaultEditorKit.pasteAction,
-                            "CUT", DefaultEditorKit.cutAction,
-                 "control INSERT", DefaultEditorKit.copyAction,
-                   "shift INSERT", DefaultEditorKit.pasteAction,
-                   "shift DELETE", DefaultEditorKit.cutAction,
-                      "control A", DefaultEditorKit.selectAllAction,
-             "control BACK_SLASH", "unselect"/*DefaultEditorKit.unselectAction*/,
-                     "shift LEFT", DefaultEditorKit.selectionBackwardAction,
-                    "shift RIGHT", DefaultEditorKit.selectionForwardAction,
-                   "control LEFT", DefaultEditorKit.previousWordAction,
-                  "control RIGHT", DefaultEditorKit.nextWordAction,
-             "control shift LEFT", DefaultEditorKit.selectionPreviousWordAction,
-            "control shift RIGHT", DefaultEditorKit.selectionNextWordAction,
-                           "HOME", DefaultEditorKit.beginLineAction,
-                            "END", DefaultEditorKit.endLineAction,
-                     "shift HOME", DefaultEditorKit.selectionBeginLineAction,
-                      "shift END", DefaultEditorKit.selectionEndLineAction,
-                     "BACK_SPACE", DefaultEditorKit.deletePrevCharAction,
-               "shift BACK_SPACE", DefaultEditorKit.deletePrevCharAction,
-                         "ctrl H", DefaultEditorKit.deletePrevCharAction,
-                         "DELETE", DefaultEditorKit.deleteNextCharAction,
-                    "ctrl DELETE", DefaultEditorKit.deleteNextWordAction,
-                "ctrl BACK_SPACE", DefaultEditorKit.deletePrevWordAction,
-                          "RIGHT", DefaultEditorKit.forwardAction,
-                           "LEFT", DefaultEditorKit.backwardAction,
-                       "KP_RIGHT", DefaultEditorKit.forwardAction,
-                        "KP_LEFT", DefaultEditorKit.backwardAction,
-                          "ENTER", JTextField.notifyAction,
-                "control shift O", "toggle-componentOrientation"/*DefaultEditorKit.toggleComponentOrientation*/
-        });
-
-        Object passwordInputMap = new UIDefaults.LazyInputMap(new Object[] {
-                      "control C", DefaultEditorKit.copyAction,
-                      "control V", DefaultEditorKit.pasteAction,
-                      "control X", DefaultEditorKit.cutAction,
-                           "COPY", DefaultEditorKit.copyAction,
-                          "PASTE", DefaultEditorKit.pasteAction,
-                            "CUT", DefaultEditorKit.cutAction,
-                 "control INSERT", DefaultEditorKit.copyAction,
-                   "shift INSERT", DefaultEditorKit.pasteAction,
-                   "shift DELETE", DefaultEditorKit.cutAction,
-                      "control A", DefaultEditorKit.selectAllAction,
-             "control BACK_SLASH", "unselect"/*DefaultEditorKit.unselectAction*/,
-                     "shift LEFT", DefaultEditorKit.selectionBackwardAction,
-                    "shift RIGHT", DefaultEditorKit.selectionForwardAction,
-                   "control LEFT", DefaultEditorKit.beginLineAction,
-                  "control RIGHT", DefaultEditorKit.endLineAction,
-             "control shift LEFT", DefaultEditorKit.selectionBeginLineAction,
-            "control shift RIGHT", DefaultEditorKit.selectionEndLineAction,
-                           "HOME", DefaultEditorKit.beginLineAction,
-                            "END", DefaultEditorKit.endLineAction,
-                     "shift HOME", DefaultEditorKit.selectionBeginLineAction,
-                      "shift END", DefaultEditorKit.selectionEndLineAction,
-                     "BACK_SPACE", DefaultEditorKit.deletePrevCharAction,
-               "shift BACK_SPACE", DefaultEditorKit.deletePrevCharAction,
-                         "ctrl H", DefaultEditorKit.deletePrevCharAction,
-                         "DELETE", DefaultEditorKit.deleteNextCharAction,
-                          "RIGHT", DefaultEditorKit.forwardAction,
-                           "LEFT", DefaultEditorKit.backwardAction,
-                       "KP_RIGHT", DefaultEditorKit.forwardAction,
-                        "KP_LEFT", DefaultEditorKit.backwardAction,
-                          "ENTER", JTextField.notifyAction,
-                "control shift O", "toggle-componentOrientation"/*DefaultEditorKit.toggleComponentOrientation*/
-        });
-
-        Object multilineInputMap = new UIDefaults.LazyInputMap(new Object[] {
-                      "control C", DefaultEditorKit.copyAction,
-                      "control V", DefaultEditorKit.pasteAction,
-                      "control X", DefaultEditorKit.cutAction,
-                           "COPY", DefaultEditorKit.copyAction,
-                          "PASTE", DefaultEditorKit.pasteAction,
-                            "CUT", DefaultEditorKit.cutAction,
-                 "control INSERT", DefaultEditorKit.copyAction,
-                   "shift INSERT", DefaultEditorKit.pasteAction,
-                   "shift DELETE", DefaultEditorKit.cutAction,
-                     "shift LEFT", DefaultEditorKit.selectionBackwardAction,
-                    "shift RIGHT", DefaultEditorKit.selectionForwardAction,
-                   "control LEFT", DefaultEditorKit.previousWordAction,
-                  "control RIGHT", DefaultEditorKit.nextWordAction,
-             "control shift LEFT", DefaultEditorKit.selectionPreviousWordAction,
-            "control shift RIGHT", DefaultEditorKit.selectionNextWordAction,
-                      "control A", DefaultEditorKit.selectAllAction,
-             "control BACK_SLASH", "unselect"/*DefaultEditorKit.unselectAction*/,
-                           "HOME", DefaultEditorKit.beginLineAction,
-                            "END", DefaultEditorKit.endLineAction,
-                     "shift HOME", DefaultEditorKit.selectionBeginLineAction,
-                      "shift END", DefaultEditorKit.selectionEndLineAction,
-                   "control HOME", DefaultEditorKit.beginAction,
-                    "control END", DefaultEditorKit.endAction,
-             "control shift HOME", DefaultEditorKit.selectionBeginAction,
-              "control shift END", DefaultEditorKit.selectionEndAction,
-                             "UP", DefaultEditorKit.upAction,
-                           "DOWN", DefaultEditorKit.downAction,
-                     "BACK_SPACE", DefaultEditorKit.deletePrevCharAction,
-               "shift BACK_SPACE", DefaultEditorKit.deletePrevCharAction,
-                         "ctrl H", DefaultEditorKit.deletePrevCharAction,
-                         "DELETE", DefaultEditorKit.deleteNextCharAction,
-                    "ctrl DELETE", DefaultEditorKit.deleteNextWordAction,
-                "ctrl BACK_SPACE", DefaultEditorKit.deletePrevWordAction,
-                          "RIGHT", DefaultEditorKit.forwardAction,
-                           "LEFT", DefaultEditorKit.backwardAction,
-                       "KP_RIGHT", DefaultEditorKit.forwardAction,
-                        "KP_LEFT", DefaultEditorKit.backwardAction,
-                        "PAGE_UP", DefaultEditorKit.pageUpAction,
-                      "PAGE_DOWN", DefaultEditorKit.pageDownAction,
-                  "shift PAGE_UP", "selection-page-up",
-                "shift PAGE_DOWN", "selection-page-down",
-             "ctrl shift PAGE_UP", "selection-page-left",
-           "ctrl shift PAGE_DOWN", "selection-page-right",
-                       "shift UP", DefaultEditorKit.selectionUpAction,
-                     "shift DOWN", DefaultEditorKit.selectionDownAction,
-                          "ENTER", DefaultEditorKit.insertBreakAction,
-                            "TAB", DefaultEditorKit.insertTabAction,
-                      "control T", "next-link-action",
-                "control shift T", "previous-link-action",
-                  "control SPACE", "activate-link-action",
-                "control shift O", "toggle-componentOrientation"/*DefaultEditorKit.toggleComponentOrientation*/
-        });
-
-        Object menuItemAcceleratorDelimiter = "+";
-
-        Object ControlBackgroundColor = new WindowsDesktopProperty(
-                                                       "win.3d.backgroundColor",
-                                                        table.get("control"));
-        Object ControlLightColor      = new WindowsDesktopProperty(
-                                                       "win.3d.lightColor",
-                                                        table.get("controlHighlight"));
-        Object ControlHighlightColor  = new WindowsDesktopProperty(
-                                                       "win.3d.highlightColor",
-                                                        table.get("controlLtHighlight"));
-        Object ControlShadowColor     = new WindowsDesktopProperty(
-                                                       "win.3d.shadowColor",
-                                                        table.get("controlShadow"));
-        Object ControlDarkShadowColor = new WindowsDesktopProperty(
-                                                       "win.3d.darkShadowColor",
-                                                        table.get("controlDkShadow"));
-        Object ControlTextColor       = new WindowsDesktopProperty(
-                                                       "win.button.textColor",
-                                                        table.get("controlText"));
-        Object MenuBackgroundColor    = new WindowsDesktopProperty(
-                                                       "win.menu.backgroundColor",
-                                                        table.get("menu"));
-        Object MenuBarBackgroundColor = new WindowsDesktopProperty(
-                                                       "win.menubar.backgroundColor",
-                                                        table.get("menu"));
-        Object MenuTextColor          = new WindowsDesktopProperty(
-                                                       "win.menu.textColor",
-                                                        table.get("menuText"));
-        Object SelectionBackgroundColor = new WindowsDesktopProperty(
-                                                       "win.item.highlightColor",
-                                                        table.get("textHighlight"));
-        Object SelectionTextColor     = new WindowsDesktopProperty(
-                                                       "win.item.highlightTextColor",
-                                                        table.get("textHighlightText"));
-        Object WindowBackgroundColor  = new WindowsDesktopProperty(
-                                                       "win.frame.backgroundColor",
-                                                        table.get("window"));
-        Object WindowTextColor        = new WindowsDesktopProperty(
-                                                       "win.frame.textColor",
-                                                        table.get("windowText"));
-        Object WindowBorderWidth      = new WindowsDesktopProperty(
-                                                       "win.frame.sizingBorderWidth",
-                                                       Integer.valueOf(1));
-        Object TitlePaneHeight        = new WindowsDesktopProperty(
-                                                       "win.frame.captionHeight",
-                                                       Integer.valueOf(18));
-        Object TitleButtonWidth       = new WindowsDesktopProperty(
-                                                       "win.frame.captionButtonWidth",
-                                                       Integer.valueOf(16));
-        Object TitleButtonHeight      = new WindowsDesktopProperty(
-                                                       "win.frame.captionButtonHeight",
-                                                       Integer.valueOf(16));
-        Object InactiveTextColor      = new WindowsDesktopProperty(
-                                                       "win.text.grayedTextColor",
-                                                        table.get("textInactiveText"));
-        Object ScrollbarBackgroundColor = new WindowsDesktopProperty(
-                                                       "win.scrollbar.backgroundColor",
-                                                        table.get("scrollbar"));
-        Object buttonFocusColor = new FocusColorProperty();
-
-        Object TextBackground         = new XPColorValue(Part.EP_EDIT, null, Prop.FILLCOLOR,
-                                                         WindowBackgroundColor);
-        //The following four lines were commented out as part of bug 4991597
-        //This code *is* correct, however it differs from WindowsXP and is, apparently
-        //a Windows XP bug. Until Windows fixes this bug, we shall also exhibit the same
-        //behavior
-        //Object ReadOnlyTextBackground = new XPColorValue(Part.EP_EDITTEXT, State.READONLY, Prop.FILLCOLOR,
-        //                                                 ControlBackgroundColor);
-        //Object DisabledTextBackground = new XPColorValue(Part.EP_EDITTEXT, State.DISABLED, Prop.FILLCOLOR,
-        //                                                 ControlBackgroundColor);
-        Object ReadOnlyTextBackground = ControlBackgroundColor;
-        Object DisabledTextBackground = ControlBackgroundColor;
-
-        Object MenuFont = dialogPlain12;
-        Object FixedControlFont = monospacedPlain12;
-        Object ControlFont = dialogPlain12;
-        Object MessageFont = dialogPlain12;
-        Object WindowFont = dialogBold12;
-        Object ToolTipFont = sansSerifPlain12;
-        Object IconFont = ControlFont;
-
-        Object scrollBarWidth = new WindowsDesktopProperty("win.scrollbar.width", Integer.valueOf(16));
-
-        Object menuBarHeight = new WindowsDesktopProperty("win.menu.height", null);
-
-        Object hotTrackingOn = new WindowsDesktopProperty("win.item.hotTrackingOn", true);
-
-        Object showMnemonics = new WindowsDesktopProperty("win.menu.keyboardCuesOn", Boolean.TRUE);
-
-        if (useSystemFontSettings) {
-            MenuFont = getDesktopFontValue("win.menu.font", MenuFont);
-            FixedControlFont = getDesktopFontValue("win.ansiFixed.font", FixedControlFont);
-            ControlFont = getDesktopFontValue("win.defaultGUI.font", ControlFont);
-            MessageFont = getDesktopFontValue("win.messagebox.font", MessageFont);
-            WindowFont = getDesktopFontValue("win.frame.captionFont", WindowFont);
-            IconFont    = getDesktopFontValue("win.icon.font", IconFont);
-            ToolTipFont = getDesktopFontValue("win.tooltip.font", ToolTipFont);
-
-            /* Put the desktop AA settings in the defaults.
-             * JComponent.setUI() retrieves this and makes it available
-             * as a client property on the JComponent. Use the same key name
-             * for both client property and UIDefaults.
-             * Also need to set up listeners for changes in these settings.
-             */
-            SwingUtilities2.putAATextInfo(true, table);
-            this.aaSettings =
-                new FontDesktopProperty(SunToolkit.DESKTOPFONTHINTS);
-        }
-        if (useSystemFontSizeSettings) {
-            MenuFont = new WindowsFontSizeProperty("win.menu.font.height", Font.DIALOG, Font.PLAIN, 12);
-            FixedControlFont = new WindowsFontSizeProperty("win.ansiFixed.font.height", Font.MONOSPACED,
-                       Font.PLAIN, 12);
-            ControlFont = new WindowsFontSizeProperty("win.defaultGUI.font.height", Font.DIALOG, Font.PLAIN, 12);
-            MessageFont = new WindowsFontSizeProperty("win.messagebox.font.height", Font.DIALOG, Font.PLAIN, 12);
-            WindowFont = new WindowsFontSizeProperty("win.frame.captionFont.height", Font.DIALOG, Font.BOLD, 12);
-            ToolTipFont = new WindowsFontSizeProperty("win.tooltip.font.height", Font.SANS_SERIF, Font.PLAIN, 12);
-            IconFont    = new WindowsFontSizeProperty("win.icon.font.height", Font.DIALOG, Font.PLAIN, 12);
-        }
-
-
-        if (!(this instanceof WindowsClassicLookAndFeel) &&
-            (OSInfo.getOSType() == OSInfo.OSType.WINDOWS &&
-             OSInfo.getWindowsVersion().compareTo(OSInfo.WINDOWS_XP) >= 0) &&
-            AccessController.doPrivileged(new GetPropertyAction("swing.noxp")) == null) {
-
-            // These desktop properties are not used directly, but are needed to
-            // trigger realoading of UI's.
-            this.themeActive = new TriggerDesktopProperty("win.xpstyle.themeActive");
-            this.dllName     = new TriggerDesktopProperty("win.xpstyle.dllName");
-            this.colorName   = new TriggerDesktopProperty("win.xpstyle.colorName");
-            this.sizeName    = new TriggerDesktopProperty("win.xpstyle.sizeName");
-        }
-
-
-        Object[] defaults = {
-            // *** Auditory Feedback
-            // this key defines which of the various cues to render
-            // Overridden from BasicL&F. This L&F should play all sounds
-            // all the time. The infrastructure decides what to play.
-            // This is disabled until sound bugs can be resolved.
-            "AuditoryCues.playList", null, // table.get("AuditoryCues.cueList"),
-
-            "Application.useSystemFontSettings", Boolean.valueOf(useSystemFontSettings),
-
-            "TextField.focusInputMap", fieldInputMap,
-            "PasswordField.focusInputMap", passwordInputMap,
-            "TextArea.focusInputMap", multilineInputMap,
-            "TextPane.focusInputMap", multilineInputMap,
-            "EditorPane.focusInputMap", multilineInputMap,
-
-            // Buttons
-            "Button.font", ControlFont,
-            "Button.background", ControlBackgroundColor,
-            // Button.foreground, Button.shadow, Button.darkShadow,
-            // Button.disabledForground, and Button.disabledShadow are only
-            // used for Windows Classic. Windows XP will use colors
-            // from the current visual style.
-            "Button.foreground", ControlTextColor,
-            "Button.shadow", ControlShadowColor,
-            "Button.darkShadow", ControlDarkShadowColor,
-            "Button.light", ControlLightColor,
-            "Button.highlight", ControlHighlightColor,
-            "Button.disabledForeground", InactiveTextColor,
-            "Button.disabledShadow", ControlHighlightColor,
-            "Button.focus", buttonFocusColor,
-            "Button.dashedRectGapX", new XPValue(Integer.valueOf(3), Integer.valueOf(5)),
-            "Button.dashedRectGapY", new XPValue(Integer.valueOf(3), Integer.valueOf(4)),
-            "Button.dashedRectGapWidth", new XPValue(Integer.valueOf(6), Integer.valueOf(10)),
-            "Button.dashedRectGapHeight", new XPValue(Integer.valueOf(6), Integer.valueOf(8)),
-            "Button.textShiftOffset", new XPValue(Integer.valueOf(0),
-                                                  Integer.valueOf(1)),
-            // W2K keyboard navigation hidding.
-            "Button.showMnemonics", showMnemonics,
-            "Button.focusInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                            "SPACE", "pressed",
-                   "released SPACE", "released"
-                 }),
-
-            "Caret.width",
-                  new WindowsDesktopProperty("win.caret.width", null),
-
-            "CheckBox.font", ControlFont,
-            "CheckBox.interiorBackground", WindowBackgroundColor,
-            "CheckBox.background", ControlBackgroundColor,
-            "CheckBox.foreground", WindowTextColor,
-            "CheckBox.shadow", ControlShadowColor,
-            "CheckBox.darkShadow", ControlDarkShadowColor,
-            "CheckBox.light", ControlLightColor,
-            "CheckBox.highlight", ControlHighlightColor,
-            "CheckBox.focus", buttonFocusColor,
-            "CheckBox.focusInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                            "SPACE", "pressed",
-                   "released SPACE", "released"
-                 }),
-            // margin is 2 all the way around, BasicBorders.RadioButtonBorder
-            // (checkbox uses RadioButtonBorder) is 2 all the way around too.
-            "CheckBox.totalInsets", new Insets(4, 4, 4, 4),
-
-            "CheckBoxMenuItem.font", MenuFont,
-            "CheckBoxMenuItem.background", MenuBackgroundColor,
-            "CheckBoxMenuItem.foreground", MenuTextColor,
-            "CheckBoxMenuItem.selectionForeground", SelectionTextColor,
-            "CheckBoxMenuItem.selectionBackground", SelectionBackgroundColor,
-            "CheckBoxMenuItem.acceleratorForeground", MenuTextColor,
-            "CheckBoxMenuItem.acceleratorSelectionForeground", SelectionTextColor,
-            "CheckBoxMenuItem.commandSound", "win.sound.menuCommand",
-
-            "ComboBox.font", ControlFont,
-            "ComboBox.background", WindowBackgroundColor,
-            "ComboBox.foreground", WindowTextColor,
-            "ComboBox.buttonBackground", ControlBackgroundColor,
-            "ComboBox.buttonShadow", ControlShadowColor,
-            "ComboBox.buttonDarkShadow", ControlDarkShadowColor,
-            "ComboBox.buttonHighlight", ControlHighlightColor,
-            "ComboBox.selectionBackground", SelectionBackgroundColor,
-            "ComboBox.selectionForeground", SelectionTextColor,
-            "ComboBox.editorBorder", new XPValue(new EmptyBorder(1,4,1,1),
-                                                 new EmptyBorder(1,4,1,4)),
-            "ComboBox.disabledBackground",
-                        new XPColorValue(Part.CP_COMBOBOX, State.DISABLED,
-                        Prop.FILLCOLOR, DisabledTextBackground),
-            "ComboBox.disabledForeground",
-                        new XPColorValue(Part.CP_COMBOBOX, State.DISABLED,
-                        Prop.TEXTCOLOR, InactiveTextColor),
-            "ComboBox.ancestorInputMap", new UIDefaults.LazyInputMap(new Object[] {
-                   "ESCAPE", "hidePopup",
-                  "PAGE_UP", "pageUpPassThrough",
-                "PAGE_DOWN", "pageDownPassThrough",
-                     "HOME", "homePassThrough",
-                      "END", "endPassThrough",
-                     "DOWN", "selectNext2",
-                  "KP_DOWN", "selectNext2",
-                       "UP", "selectPrevious2",
-                    "KP_UP", "selectPrevious2",
-                    "ENTER", "enterPressed",
-                       "F4", "togglePopup",
-                 "alt DOWN", "togglePopup",
-              "alt KP_DOWN", "togglePopup",
-                   "alt UP", "togglePopup",
-                "alt KP_UP", "togglePopup"
-              }),
-
-            // DeskTop.
-            "Desktop.background", new WindowsDesktopProperty(
-                                                 "win.mdi.backgroundColor",
-                                                  table.get("desktop")),
-            "Desktop.ancestorInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                   "ctrl F5", "restore",
-                   "ctrl F4", "close",
-                   "ctrl F7", "move",
-                   "ctrl F8", "resize",
-                   "RIGHT", "right",
-                   "KP_RIGHT", "right",
-                   "LEFT", "left",
-                   "KP_LEFT", "left",
-                   "UP", "up",
-                   "KP_UP", "up",
-                   "DOWN", "down",
-                   "KP_DOWN", "down",
-                   "ESCAPE", "escape",
-                   "ctrl F9", "minimize",
-                   "ctrl F10", "maximize",
-                   "ctrl F6", "selectNextFrame",
-                   "ctrl TAB", "selectNextFrame",
-                   "ctrl alt F6", "selectNextFrame",
-                   "shift ctrl alt F6", "selectPreviousFrame",
-                   "ctrl F12", "navigateNext",
-                   "shift ctrl F12", "navigatePrevious"
-               }),
-
-            // DesktopIcon
-            "DesktopIcon.width", Integer.valueOf(160),
-
-            "EditorPane.font", ControlFont,
-            "EditorPane.background", WindowBackgroundColor,
-            "EditorPane.foreground", WindowTextColor,
-            "EditorPane.selectionBackground", SelectionBackgroundColor,
-            "EditorPane.selectionForeground", SelectionTextColor,
-            "EditorPane.caretForeground", WindowTextColor,
-            "EditorPane.inactiveForeground", InactiveTextColor,
-            "EditorPane.inactiveBackground", WindowBackgroundColor,
-            "EditorPane.disabledBackground", DisabledTextBackground,
-
-            "FileChooser.homeFolderIcon",  new LazyWindowsIcon(null,
-                                                               "icons/HomeFolder.gif"),
-            "FileChooser.listFont", IconFont,
-            "FileChooser.listViewBackground", new XPColorValue(Part.LVP_LISTVIEW, null, Prop.FILLCOLOR,
-                                                               WindowBackgroundColor),
-            "FileChooser.listViewBorder", new XPBorderValue(Part.LVP_LISTVIEW,
-               (LazyValue) t -> BorderUIResource.getLoweredBevelBorderUIResource()),
-            "FileChooser.listViewIcon",    new LazyWindowsIcon("fileChooserIcon ListView",
-                                                               "icons/ListView.gif"),
-            "FileChooser.listViewWindowsStyle", Boolean.TRUE,
-            "FileChooser.detailsViewIcon", new LazyWindowsIcon("fileChooserIcon DetailsView",
-                                                               "icons/DetailsView.gif"),
-            "FileChooser.viewMenuIcon", new LazyWindowsIcon("fileChooserIcon ViewMenu",
-                                                            "icons/ListView.gif"),
-            "FileChooser.upFolderIcon",    new LazyWindowsIcon("fileChooserIcon UpFolder",
-                                                               "icons/UpFolder.gif"),
-            "FileChooser.newFolderIcon",   new LazyWindowsIcon("fileChooserIcon NewFolder",
-                                                               "icons/NewFolder.gif"),
-            "FileChooser.useSystemExtensionHiding", Boolean.TRUE,
-
-            "FileChooser.usesSingleFilePane", Boolean.TRUE,
-            "FileChooser.noPlacesBar", new WindowsDesktopProperty("win.comdlg.noPlacesBar",
-                                                                  Boolean.FALSE),
-            "FileChooser.ancestorInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                     "ESCAPE", "cancelSelection",
-                     "F2", "editFileName",
-                     "F5", "refresh",
-                     "BACK_SPACE", "Go Up"
-                 }),
-
-            "FileView.directoryIcon", SwingUtilities2.makeIcon(getClass(),
-                                                               WindowsLookAndFeel.class,
-                                                               "icons/Directory.gif"),
-            "FileView.fileIcon", SwingUtilities2.makeIcon(getClass(),
-                                                          WindowsLookAndFeel.class,
-                                                          "icons/File.gif"),
-            "FileView.computerIcon", SwingUtilities2.makeIcon(getClass(),
-                                                              WindowsLookAndFeel.class,
-                                                              "icons/Computer.gif"),
-            "FileView.hardDriveIcon", SwingUtilities2.makeIcon(getClass(),
-                                                               WindowsLookAndFeel.class,
-                                                               "icons/HardDrive.gif"),
-            "FileView.floppyDriveIcon", SwingUtilities2.makeIcon(getClass(),
-                                                                 WindowsLookAndFeel.class,
-                                                                 "icons/FloppyDrive.gif"),
-
-            "FormattedTextField.font", ControlFont,
-            "InternalFrame.titleFont", WindowFont,
-            "InternalFrame.titlePaneHeight",   TitlePaneHeight,
-            "InternalFrame.titleButtonWidth",  TitleButtonWidth,
-            "InternalFrame.titleButtonHeight", TitleButtonHeight,
-            "InternalFrame.titleButtonToolTipsOn", hotTrackingOn,
-            "InternalFrame.borderColor", ControlBackgroundColor,
-            "InternalFrame.borderShadow", ControlShadowColor,
-            "InternalFrame.borderDarkShadow", ControlDarkShadowColor,
-            "InternalFrame.borderHighlight", ControlHighlightColor,
-            "InternalFrame.borderLight", ControlLightColor,
-            "InternalFrame.borderWidth", WindowBorderWidth,
-            "InternalFrame.minimizeIconBackground", ControlBackgroundColor,
-            "InternalFrame.resizeIconHighlight", ControlLightColor,
-            "InternalFrame.resizeIconShadow", ControlShadowColor,
-            "InternalFrame.activeBorderColor", new WindowsDesktopProperty(
-                                                       "win.frame.activeBorderColor",
-                                                       table.get("windowBorder")),
-            "InternalFrame.inactiveBorderColor", new WindowsDesktopProperty(
-                                                       "win.frame.inactiveBorderColor",
-                                                       table.get("windowBorder")),
-            "InternalFrame.activeTitleBackground", new WindowsDesktopProperty(
-                                                        "win.frame.activeCaptionColor",
-                                                         table.get("activeCaption")),
-            "InternalFrame.activeTitleGradient", new WindowsDesktopProperty(
-                                                        "win.frame.activeCaptionGradientColor",
-                                                         table.get("activeCaption")),
-            "InternalFrame.activeTitleForeground", new WindowsDesktopProperty(
-                                                        "win.frame.captionTextColor",
-                                                         table.get("activeCaptionText")),
-            "InternalFrame.inactiveTitleBackground", new WindowsDesktopProperty(
-                                                        "win.frame.inactiveCaptionColor",
-                                                         table.get("inactiveCaption")),
-            "InternalFrame.inactiveTitleGradient", new WindowsDesktopProperty(
-                                                        "win.frame.inactiveCaptionGradientColor",
-                                                         table.get("inactiveCaption")),
-            "InternalFrame.inactiveTitleForeground", new WindowsDesktopProperty(
-                                                        "win.frame.inactiveCaptionTextColor",
-                                                         table.get("inactiveCaptionText")),
-
-            "InternalFrame.maximizeIcon",
-                WindowsIconFactory.createFrameMaximizeIcon(),
-            "InternalFrame.minimizeIcon",
-                WindowsIconFactory.createFrameMinimizeIcon(),
-            "InternalFrame.iconifyIcon",
-                WindowsIconFactory.createFrameIconifyIcon(),
-            "InternalFrame.closeIcon",
-                WindowsIconFactory.createFrameCloseIcon(),
-            "InternalFrame.icon",
-                (LazyValue) t -> new WindowsInternalFrameTitlePane.ScalableIconUIResource(new Object[]{
-                    // The constructor takes one arg: an array of UIDefaults.LazyValue
-                    // representing the icons
-                        SwingUtilities2.makeIcon(getClass(), BasicLookAndFeel.class, "icons/JavaCup16.png"),
-                        SwingUtilities2.makeIcon(getClass(), WindowsLookAndFeel.class, "icons/JavaCup32.png")
-                }),
-            // Internal Frame Auditory Cue Mappings
-            "InternalFrame.closeSound", "win.sound.close",
-            "InternalFrame.maximizeSound", "win.sound.maximize",
-            "InternalFrame.minimizeSound", "win.sound.minimize",
-            "InternalFrame.restoreDownSound", "win.sound.restoreDown",
-            "InternalFrame.restoreUpSound", "win.sound.restoreUp",
-
-            "InternalFrame.windowBindings", new Object[] {
-                "shift ESCAPE", "showSystemMenu",
-                  "ctrl SPACE", "showSystemMenu",
-                      "ESCAPE", "hideSystemMenu"},
-
-            // Label
-            "Label.font", ControlFont,
-            "Label.background", ControlBackgroundColor,
-            "Label.foreground", WindowTextColor,
-            "Label.disabledForeground", InactiveTextColor,
-            "Label.disabledShadow", ControlHighlightColor,
-
-            // List.
-            "List.font", ControlFont,
-            "List.background", WindowBackgroundColor,
-            "List.foreground", WindowTextColor,
-            "List.selectionBackground", SelectionBackgroundColor,
-            "List.selectionForeground", SelectionTextColor,
-            "List.lockToPositionOnScroll", Boolean.TRUE,
-            "List.focusInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                           "ctrl C", "copy",
-                           "ctrl V", "paste",
-                           "ctrl X", "cut",
-                             "COPY", "copy",
-                            "PASTE", "paste",
-                              "CUT", "cut",
-                   "control INSERT", "copy",
-                     "shift INSERT", "paste",
-                     "shift DELETE", "cut",
-                               "UP", "selectPreviousRow",
-                            "KP_UP", "selectPreviousRow",
-                         "shift UP", "selectPreviousRowExtendSelection",
-                      "shift KP_UP", "selectPreviousRowExtendSelection",
-                    "ctrl shift UP", "selectPreviousRowExtendSelection",
-                 "ctrl shift KP_UP", "selectPreviousRowExtendSelection",
-                          "ctrl UP", "selectPreviousRowChangeLead",
-                       "ctrl KP_UP", "selectPreviousRowChangeLead",
-                             "DOWN", "selectNextRow",
-                          "KP_DOWN", "selectNextRow",
-                       "shift DOWN", "selectNextRowExtendSelection",
-                    "shift KP_DOWN", "selectNextRowExtendSelection",
-                  "ctrl shift DOWN", "selectNextRowExtendSelection",
-               "ctrl shift KP_DOWN", "selectNextRowExtendSelection",
-                        "ctrl DOWN", "selectNextRowChangeLead",
-                     "ctrl KP_DOWN", "selectNextRowChangeLead",
-                             "LEFT", "selectPreviousColumn",
-                          "KP_LEFT", "selectPreviousColumn",
-                       "shift LEFT", "selectPreviousColumnExtendSelection",
-                    "shift KP_LEFT", "selectPreviousColumnExtendSelection",
-                  "ctrl shift LEFT", "selectPreviousColumnExtendSelection",
-               "ctrl shift KP_LEFT", "selectPreviousColumnExtendSelection",
-                        "ctrl LEFT", "selectPreviousColumnChangeLead",
-                     "ctrl KP_LEFT", "selectPreviousColumnChangeLead",
-                            "RIGHT", "selectNextColumn",
-                         "KP_RIGHT", "selectNextColumn",
-                      "shift RIGHT", "selectNextColumnExtendSelection",
-                   "shift KP_RIGHT", "selectNextColumnExtendSelection",
-                 "ctrl shift RIGHT", "selectNextColumnExtendSelection",
-              "ctrl shift KP_RIGHT", "selectNextColumnExtendSelection",
-                       "ctrl RIGHT", "selectNextColumnChangeLead",
-                    "ctrl KP_RIGHT", "selectNextColumnChangeLead",
-                             "HOME", "selectFirstRow",
-                       "shift HOME", "selectFirstRowExtendSelection",
-                  "ctrl shift HOME", "selectFirstRowExtendSelection",
-                        "ctrl HOME", "selectFirstRowChangeLead",
-                              "END", "selectLastRow",
-                        "shift END", "selectLastRowExtendSelection",
-                   "ctrl shift END", "selectLastRowExtendSelection",
-                         "ctrl END", "selectLastRowChangeLead",
-                          "PAGE_UP", "scrollUp",
-                    "shift PAGE_UP", "scrollUpExtendSelection",
-               "ctrl shift PAGE_UP", "scrollUpExtendSelection",
-                     "ctrl PAGE_UP", "scrollUpChangeLead",
-                        "PAGE_DOWN", "scrollDown",
-                  "shift PAGE_DOWN", "scrollDownExtendSelection",
-             "ctrl shift PAGE_DOWN", "scrollDownExtendSelection",
-                   "ctrl PAGE_DOWN", "scrollDownChangeLead",
-                           "ctrl A", "selectAll",
-                       "ctrl SLASH", "selectAll",
-                  "ctrl BACK_SLASH", "clearSelection",
-                            "SPACE", "addToSelection",
-                       "ctrl SPACE", "toggleAndAnchor",
-                      "shift SPACE", "extendTo",
-                 "ctrl shift SPACE", "moveSelectionTo"
-                 }),
-
-            // PopupMenu
-            "PopupMenu.font", MenuFont,
-            "PopupMenu.background", MenuBackgroundColor,
-            "PopupMenu.foreground", MenuTextColor,
-            "PopupMenu.popupSound", "win.sound.menuPopup",
-            "PopupMenu.consumeEventOnClose", Boolean.TRUE,
-
-            // Menus
-            "Menu.font", MenuFont,
-            "Menu.foreground", MenuTextColor,
-            "Menu.background", MenuBackgroundColor,
-            "Menu.useMenuBarBackgroundForTopLevel", Boolean.TRUE,
-            "Menu.selectionForeground", SelectionTextColor,
-            "Menu.selectionBackground", SelectionBackgroundColor,
-            "Menu.acceleratorForeground", MenuTextColor,
-            "Menu.acceleratorSelectionForeground", SelectionTextColor,
-            "Menu.menuPopupOffsetX", Integer.valueOf(0),
-            "Menu.menuPopupOffsetY", Integer.valueOf(0),
-            "Menu.submenuPopupOffsetX", Integer.valueOf(-4),
-            "Menu.submenuPopupOffsetY", Integer.valueOf(-3),
-            "Menu.crossMenuMnemonic", Boolean.FALSE,
-            "Menu.preserveTopLevelSelection", Boolean.TRUE,
-
-            // MenuBar.
-            "MenuBar.font", MenuFont,
-            "MenuBar.background", new XPValue(MenuBarBackgroundColor,
-                                              MenuBackgroundColor),
-            "MenuBar.foreground", MenuTextColor,
-            "MenuBar.shadow", ControlShadowColor,
-            "MenuBar.highlight", ControlHighlightColor,
-            "MenuBar.height", menuBarHeight,
-            "MenuBar.rolloverEnabled", hotTrackingOn,
-            "MenuBar.windowBindings", new Object[] {
-                "F10", "takeFocus" },
-
-            "MenuItem.font", MenuFont,
-            "MenuItem.acceleratorFont", MenuFont,
-            "MenuItem.foreground", MenuTextColor,
-            "MenuItem.background", MenuBackgroundColor,
-            "MenuItem.selectionForeground", SelectionTextColor,
-            "MenuItem.selectionBackground", SelectionBackgroundColor,
-            "MenuItem.disabledForeground", InactiveTextColor,
-            "MenuItem.acceleratorForeground", MenuTextColor,
-            "MenuItem.acceleratorSelectionForeground", SelectionTextColor,
-            "MenuItem.acceleratorDelimiter", menuItemAcceleratorDelimiter,
-                 // Menu Item Auditory Cue Mapping
-            "MenuItem.commandSound", "win.sound.menuCommand",
-             // indicates that keyboard navigation won't skip disabled menu items
-            "MenuItem.disabledAreNavigable", Boolean.TRUE,
-
-            "RadioButton.font", ControlFont,
-            "RadioButton.interiorBackground", WindowBackgroundColor,
-            "RadioButton.background", ControlBackgroundColor,
-            "RadioButton.foreground", WindowTextColor,
-            "RadioButton.shadow", ControlShadowColor,
-            "RadioButton.darkShadow", ControlDarkShadowColor,
-            "RadioButton.light", ControlLightColor,
-            "RadioButton.highlight", ControlHighlightColor,
-            "RadioButton.focus", buttonFocusColor,
-            "RadioButton.focusInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                          "SPACE", "pressed",
-                 "released SPACE", "released"
-              }),
-            // margin is 2 all the way around, BasicBorders.RadioButtonBorder
-            // is 2 all the way around too.
-            "RadioButton.totalInsets", new Insets(4, 4, 4, 4),
-
-
-            "RadioButtonMenuItem.font", MenuFont,
-            "RadioButtonMenuItem.foreground", MenuTextColor,
-            "RadioButtonMenuItem.background", MenuBackgroundColor,
-            "RadioButtonMenuItem.selectionForeground", SelectionTextColor,
-            "RadioButtonMenuItem.selectionBackground", SelectionBackgroundColor,
-            "RadioButtonMenuItem.disabledForeground", InactiveTextColor,
-            "RadioButtonMenuItem.acceleratorForeground", MenuTextColor,
-            "RadioButtonMenuItem.acceleratorSelectionForeground", SelectionTextColor,
-            "RadioButtonMenuItem.commandSound", "win.sound.menuCommand",
-
-            // OptionPane.
-            "OptionPane.font", MessageFont,
-            "OptionPane.messageFont", MessageFont,
-            "OptionPane.buttonFont", MessageFont,
-            "OptionPane.background", ControlBackgroundColor,
-            "OptionPane.foreground", WindowTextColor,
-            "OptionPane.buttonMinimumWidth", new XPDLUValue(50, 50, SwingConstants.EAST),
-            "OptionPane.messageForeground", ControlTextColor,
-            "OptionPane.errorIcon",       new LazyWindowsIcon("optionPaneIcon Error",
-                                                              "icons/Error.gif"),
-            "OptionPane.informationIcon", new LazyWindowsIcon("optionPaneIcon Information",
-                                                              "icons/Inform.gif"),
-            "OptionPane.questionIcon",    new LazyWindowsIcon("optionPaneIcon Question",
-                                                              "icons/Question.gif"),
-            "OptionPane.warningIcon",     new LazyWindowsIcon("optionPaneIcon Warning",
-                                                              "icons/Warn.gif"),
-            "OptionPane.windowBindings", new Object[] {
-                "ESCAPE", "close" },
-                 // Option Pane Auditory Cue Mappings
-            "OptionPane.errorSound", "win.sound.hand", // Error
-            "OptionPane.informationSound", "win.sound.asterisk", // Info Plain
-            "OptionPane.questionSound", "win.sound.question", // Question
-            "OptionPane.warningSound", "win.sound.exclamation", // Warning
-
-            "FormattedTextField.focusInputMap",
-              new UIDefaults.LazyInputMap(new Object[] {
-                           "ctrl C", DefaultEditorKit.copyAction,
-                           "ctrl V", DefaultEditorKit.pasteAction,
-                           "ctrl X", DefaultEditorKit.cutAction,
-                             "COPY", DefaultEditorKit.copyAction,
-                            "PASTE", DefaultEditorKit.pasteAction,
-                              "CUT", DefaultEditorKit.cutAction,
-                   "control INSERT", DefaultEditorKit.copyAction,
-                     "shift INSERT", DefaultEditorKit.pasteAction,
-                     "shift DELETE", DefaultEditorKit.cutAction,
-                       "shift LEFT", DefaultEditorKit.selectionBackwardAction,
-                    "shift KP_LEFT", DefaultEditorKit.selectionBackwardAction,
-                      "shift RIGHT", DefaultEditorKit.selectionForwardAction,
-                   "shift KP_RIGHT", DefaultEditorKit.selectionForwardAction,
-                        "ctrl LEFT", DefaultEditorKit.previousWordAction,
-                     "ctrl KP_LEFT", DefaultEditorKit.previousWordAction,
-                       "ctrl RIGHT", DefaultEditorKit.nextWordAction,
-                    "ctrl KP_RIGHT", DefaultEditorKit.nextWordAction,
-                  "ctrl shift LEFT", DefaultEditorKit.selectionPreviousWordAction,
-               "ctrl shift KP_LEFT", DefaultEditorKit.selectionPreviousWordAction,
-                 "ctrl shift RIGHT", DefaultEditorKit.selectionNextWordAction,
-              "ctrl shift KP_RIGHT", DefaultEditorKit.selectionNextWordAction,
-                           "ctrl A", DefaultEditorKit.selectAllAction,
-                             "HOME", DefaultEditorKit.beginLineAction,
-                              "END", DefaultEditorKit.endLineAction,
-                       "shift HOME", DefaultEditorKit.selectionBeginLineAction,
-                        "shift END", DefaultEditorKit.selectionEndLineAction,
-                       "BACK_SPACE", DefaultEditorKit.deletePrevCharAction,
-                 "shift BACK_SPACE", DefaultEditorKit.deletePrevCharAction,
-                           "ctrl H", DefaultEditorKit.deletePrevCharAction,
-                           "DELETE", DefaultEditorKit.deleteNextCharAction,
-                      "ctrl DELETE", DefaultEditorKit.deleteNextWordAction,
-                  "ctrl BACK_SPACE", DefaultEditorKit.deletePrevWordAction,
-                            "RIGHT", DefaultEditorKit.forwardAction,
-                             "LEFT", DefaultEditorKit.backwardAction,
-                         "KP_RIGHT", DefaultEditorKit.forwardAction,
-                          "KP_LEFT", DefaultEditorKit.backwardAction,
-                            "ENTER", JTextField.notifyAction,
-                  "ctrl BACK_SLASH", "unselect",
-                   "control shift O", "toggle-componentOrientation",
-                           "ESCAPE", "reset-field-edit",
-                               "UP", "increment",
-                            "KP_UP", "increment",
-                             "DOWN", "decrement",
-                          "KP_DOWN", "decrement",
-              }),
-            "FormattedTextField.inactiveBackground", ReadOnlyTextBackground,
-            "FormattedTextField.disabledBackground", DisabledTextBackground,
-            "FormattedTextField.background", TextBackground,
-            "FormattedTextField.foreground", WindowTextColor,
-
-            // *** Panel
-            "Panel.font", ControlFont,
-            "Panel.background", ControlBackgroundColor,
-            "Panel.foreground", WindowTextColor,
-
-            // *** PasswordField
-            "PasswordField.font", ControlFont,
-            "PasswordField.background", TextBackground,
-            "PasswordField.foreground", WindowTextColor,
-            "PasswordField.inactiveForeground", InactiveTextColor,      // for disabled
-            "PasswordField.inactiveBackground", ReadOnlyTextBackground, // for readonly
-            "PasswordField.disabledBackground", DisabledTextBackground, // for disabled
-            "PasswordField.selectionBackground", SelectionBackgroundColor,
-            "PasswordField.selectionForeground", SelectionTextColor,
-            "PasswordField.caretForeground",WindowTextColor,
-            "PasswordField.echoChar", new XPValue((char)0x25CF, '*'),
-
-            // *** ProgressBar
-            "ProgressBar.font", ControlFont,
-            "ProgressBar.foreground",  SelectionBackgroundColor,
-            "ProgressBar.background", ControlBackgroundColor,
-            "ProgressBar.shadow", ControlShadowColor,
-            "ProgressBar.highlight", ControlHighlightColor,
-            "ProgressBar.selectionForeground", ControlBackgroundColor,
-            "ProgressBar.selectionBackground", SelectionBackgroundColor,
-            "ProgressBar.cellLength", Integer.valueOf(7),
-            "ProgressBar.cellSpacing", Integer.valueOf(2),
-            "ProgressBar.indeterminateInsets", new Insets(3, 3, 3, 3),
-
-            // *** RootPane.
-            // These bindings are only enabled when there is a default
-            // button set on the rootpane.
-            "RootPane.defaultButtonWindowKeyBindings", new Object[] {
-                             "ENTER", "press",
-                    "released ENTER", "release",
-                        "ctrl ENTER", "press",
-               "ctrl released ENTER", "release"
-              },
-
-            // *** ScrollBar.
-            "ScrollBar.background", ScrollbarBackgroundColor,
-            "ScrollBar.foreground", ControlBackgroundColor,
-            "ScrollBar.track", white,
-            "ScrollBar.trackForeground", ScrollbarBackgroundColor,
-            "ScrollBar.trackHighlight", black,
-            "ScrollBar.trackHighlightForeground", scrollBarTrackHighlight,
-            "ScrollBar.thumb", ControlBackgroundColor,
-            "ScrollBar.thumbHighlight", ControlHighlightColor,
-            "ScrollBar.thumbDarkShadow", ControlDarkShadowColor,
-            "ScrollBar.thumbShadow", ControlShadowColor,
-            "ScrollBar.width", scrollBarWidth,
-            "ScrollBar.ancestorInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                       "RIGHT", "positiveUnitIncrement",
-                    "KP_RIGHT", "positiveUnitIncrement",
-                        "DOWN", "positiveUnitIncrement",
-                     "KP_DOWN", "positiveUnitIncrement",
-                   "PAGE_DOWN", "positiveBlockIncrement",
-              "ctrl PAGE_DOWN", "positiveBlockIncrement",
-                        "LEFT", "negativeUnitIncrement",
-                     "KP_LEFT", "negativeUnitIncrement",
-                          "UP", "negativeUnitIncrement",
-                       "KP_UP", "negativeUnitIncrement",
-                     "PAGE_UP", "negativeBlockIncrement",
-                "ctrl PAGE_UP", "negativeBlockIncrement",
-                        "HOME", "minScroll",
-                         "END", "maxScroll"
-                 }),
-
-            // *** ScrollPane.
-            "ScrollPane.font", ControlFont,
-            "ScrollPane.background", ControlBackgroundColor,
-            "ScrollPane.foreground", ControlTextColor,
-            "ScrollPane.ancestorInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                           "RIGHT", "unitScrollRight",
-                        "KP_RIGHT", "unitScrollRight",
-                            "DOWN", "unitScrollDown",
-                         "KP_DOWN", "unitScrollDown",
-                            "LEFT", "unitScrollLeft",
-                         "KP_LEFT", "unitScrollLeft",
-                              "UP", "unitScrollUp",
-                           "KP_UP", "unitScrollUp",
-                         "PAGE_UP", "scrollUp",
-                       "PAGE_DOWN", "scrollDown",
-                    "ctrl PAGE_UP", "scrollLeft",
-                  "ctrl PAGE_DOWN", "scrollRight",
-                       "ctrl HOME", "scrollHome",
-                        "ctrl END", "scrollEnd"
-                 }),
-
-            // *** Separator
-            "Separator.background", ControlHighlightColor,
-            "Separator.foreground", ControlShadowColor,
-
-            // *** Slider.
-            "Slider.font", ControlFont,
-            "Slider.foreground", ControlBackgroundColor,
-            "Slider.background", ControlBackgroundColor,
-            "Slider.highlight", ControlHighlightColor,
-            "Slider.shadow", ControlShadowColor,
-            "Slider.focus", ControlDarkShadowColor,
-            "Slider.focusInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                       "RIGHT", "positiveUnitIncrement",
-                    "KP_RIGHT", "positiveUnitIncrement",
-                        "DOWN", "negativeUnitIncrement",
-                     "KP_DOWN", "negativeUnitIncrement",
-                   "PAGE_DOWN", "negativeBlockIncrement",
-                        "LEFT", "negativeUnitIncrement",
-                     "KP_LEFT", "negativeUnitIncrement",
-                          "UP", "positiveUnitIncrement",
-                       "KP_UP", "positiveUnitIncrement",
-                     "PAGE_UP", "positiveBlockIncrement",
-                        "HOME", "minScroll",
-                         "END", "maxScroll"
-                 }),
-
-            // Spinner
-            "Spinner.font", ControlFont,
-            "Spinner.ancestorInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                               "UP", "increment",
-                            "KP_UP", "increment",
-                             "DOWN", "decrement",
-                          "KP_DOWN", "decrement",
-               }),
-
-            // *** SplitPane
-            "SplitPane.background", ControlBackgroundColor,
-            "SplitPane.highlight", ControlHighlightColor,
-            "SplitPane.shadow", ControlShadowColor,
-            "SplitPane.darkShadow", ControlDarkShadowColor,
-            "SplitPane.dividerSize", Integer.valueOf(5),
-            "SplitPane.ancestorInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                        "UP", "negativeIncrement",
-                      "DOWN", "positiveIncrement",
-                      "LEFT", "negativeIncrement",
-                     "RIGHT", "positiveIncrement",
-                     "KP_UP", "negativeIncrement",
-                   "KP_DOWN", "positiveIncrement",
-                   "KP_LEFT", "negativeIncrement",
-                  "KP_RIGHT", "positiveIncrement",
-                      "HOME", "selectMin",
-                       "END", "selectMax",
-                        "F8", "startResize",
-                        "F6", "toggleFocus",
-                  "ctrl TAB", "focusOutForward",
-            "ctrl shift TAB", "focusOutBackward"
-               }),
-
-            // *** TabbedPane
-            "TabbedPane.tabsOverlapBorder", new XPValue(Boolean.TRUE, Boolean.FALSE),
-            "TabbedPane.tabInsets",         new XPValue(new InsetsUIResource(1, 4, 1, 4),
-                                                        new InsetsUIResource(0, 4, 1, 4)),
-            "TabbedPane.tabAreaInsets",     new XPValue(new InsetsUIResource(3, 2, 2, 2),
-                                                        new InsetsUIResource(3, 2, 0, 2)),
-            "TabbedPane.font", ControlFont,
-            "TabbedPane.background", ControlBackgroundColor,
-            "TabbedPane.foreground", ControlTextColor,
-            "TabbedPane.highlight", ControlHighlightColor,
-            "TabbedPane.light", ControlLightColor,
-            "TabbedPane.shadow", ControlShadowColor,
-            "TabbedPane.darkShadow", ControlDarkShadowColor,
-            "TabbedPane.focus", ControlTextColor,
-            "TabbedPane.focusInputMap",
-              new UIDefaults.LazyInputMap(new Object[] {
-                         "RIGHT", "navigateRight",
-                      "KP_RIGHT", "navigateRight",
-                          "LEFT", "navigateLeft",
-                       "KP_LEFT", "navigateLeft",
-                            "UP", "navigateUp",
-                         "KP_UP", "navigateUp",
-                          "DOWN", "navigateDown",
-                       "KP_DOWN", "navigateDown",
-                     "ctrl DOWN", "requestFocusForVisibleComponent",
-                  "ctrl KP_DOWN", "requestFocusForVisibleComponent",
-                }),
-            "TabbedPane.ancestorInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                         "ctrl TAB", "navigateNext",
-                   "ctrl shift TAB", "navigatePrevious",
-                   "ctrl PAGE_DOWN", "navigatePageDown",
-                     "ctrl PAGE_UP", "navigatePageUp",
-                          "ctrl UP", "requestFocus",
-                       "ctrl KP_UP", "requestFocus",
-                 }),
-
-            // *** Table
-            "Table.font", ControlFont,
-            "Table.foreground", ControlTextColor,  // cell text color
-            "Table.background", WindowBackgroundColor,  // cell background color
-            "Table.highlight", ControlHighlightColor,
-            "Table.light", ControlLightColor,
-            "Table.shadow", ControlShadowColor,
-            "Table.darkShadow", ControlDarkShadowColor,
-            "Table.selectionForeground", SelectionTextColor,
-            "Table.selectionBackground", SelectionBackgroundColor,
-            "Table.gridColor", gray,  // grid line color
-            "Table.focusCellBackground", WindowBackgroundColor,
-            "Table.focusCellForeground", ControlTextColor,
-            "Table.ancestorInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                               "ctrl C", "copy",
-                               "ctrl V", "paste",
-                               "ctrl X", "cut",
-                                 "COPY", "copy",
-                                "PASTE", "paste",
-                                  "CUT", "cut",
-                       "control INSERT", "copy",
-                         "shift INSERT", "paste",
-                         "shift DELETE", "cut",
-                                "RIGHT", "selectNextColumn",
-                             "KP_RIGHT", "selectNextColumn",
-                          "shift RIGHT", "selectNextColumnExtendSelection",
-                       "shift KP_RIGHT", "selectNextColumnExtendSelection",
-                     "ctrl shift RIGHT", "selectNextColumnExtendSelection",
-                  "ctrl shift KP_RIGHT", "selectNextColumnExtendSelection",
-                           "ctrl RIGHT", "selectNextColumnChangeLead",
-                        "ctrl KP_RIGHT", "selectNextColumnChangeLead",
-                                 "LEFT", "selectPreviousColumn",
-                              "KP_LEFT", "selectPreviousColumn",
-                           "shift LEFT", "selectPreviousColumnExtendSelection",
-                        "shift KP_LEFT", "selectPreviousColumnExtendSelection",
-                      "ctrl shift LEFT", "selectPreviousColumnExtendSelection",
-                   "ctrl shift KP_LEFT", "selectPreviousColumnExtendSelection",
-                            "ctrl LEFT", "selectPreviousColumnChangeLead",
-                         "ctrl KP_LEFT", "selectPreviousColumnChangeLead",
-                                 "DOWN", "selectNextRow",
-                              "KP_DOWN", "selectNextRow",
-                           "shift DOWN", "selectNextRowExtendSelection",
-                        "shift KP_DOWN", "selectNextRowExtendSelection",
-                      "ctrl shift DOWN", "selectNextRowExtendSelection",
-                   "ctrl shift KP_DOWN", "selectNextRowExtendSelection",
-                            "ctrl DOWN", "selectNextRowChangeLead",
-                         "ctrl KP_DOWN", "selectNextRowChangeLead",
-                                   "UP", "selectPreviousRow",
-                                "KP_UP", "selectPreviousRow",
-                             "shift UP", "selectPreviousRowExtendSelection",
-                          "shift KP_UP", "selectPreviousRowExtendSelection",
-                        "ctrl shift UP", "selectPreviousRowExtendSelection",
-                     "ctrl shift KP_UP", "selectPreviousRowExtendSelection",
-                              "ctrl UP", "selectPreviousRowChangeLead",
-                           "ctrl KP_UP", "selectPreviousRowChangeLead",
-                                 "HOME", "selectFirstColumn",
-                           "shift HOME", "selectFirstColumnExtendSelection",
-                      "ctrl shift HOME", "selectFirstRowExtendSelection",
-                            "ctrl HOME", "selectFirstRow",
-                                  "END", "selectLastColumn",
-                            "shift END", "selectLastColumnExtendSelection",
-                       "ctrl shift END", "selectLastRowExtendSelection",
-                             "ctrl END", "selectLastRow",
-                              "PAGE_UP", "scrollUpChangeSelection",
-                        "shift PAGE_UP", "scrollUpExtendSelection",
-                   "ctrl shift PAGE_UP", "scrollLeftExtendSelection",
-                         "ctrl PAGE_UP", "scrollLeftChangeSelection",
-                            "PAGE_DOWN", "scrollDownChangeSelection",
-                      "shift PAGE_DOWN", "scrollDownExtendSelection",
-                 "ctrl shift PAGE_DOWN", "scrollRightExtendSelection",
-                       "ctrl PAGE_DOWN", "scrollRightChangeSelection",
-                                  "TAB", "selectNextColumnCell",
-                            "shift TAB", "selectPreviousColumnCell",
-                                "ENTER", "selectNextRowCell",
-                          "shift ENTER", "selectPreviousRowCell",
-                               "ctrl A", "selectAll",
-                           "ctrl SLASH", "selectAll",
-                      "ctrl BACK_SLASH", "clearSelection",
-                               "ESCAPE", "cancel",
-                                   "F2", "startEditing",
-                                "SPACE", "addToSelection",
-                           "ctrl SPACE", "toggleAndAnchor",
-                          "shift SPACE", "extendTo",
-                     "ctrl shift SPACE", "moveSelectionTo",
-                                   "F8", "focusHeader"
-                 }),
-            "Table.sortIconHighlight", ControlShadowColor,
-            "Table.sortIconLight", white,
-
-            "TableHeader.font", ControlFont,
-            "TableHeader.foreground", ControlTextColor, // header text color
-            "TableHeader.background", ControlBackgroundColor, // header background
-            "TableHeader.focusCellBackground",
-                new XPValue(XPValue.NULL_VALUE,     // use default bg from XP styles
-                            WindowBackgroundColor), // or white bg otherwise
-
-            // *** TextArea
-            "TextArea.font", FixedControlFont,
-            "TextArea.background", WindowBackgroundColor,
-            "TextArea.foreground", WindowTextColor,
-            "TextArea.inactiveForeground", InactiveTextColor,
-            "TextArea.inactiveBackground", WindowBackgroundColor,
-            "TextArea.disabledBackground", DisabledTextBackground,
-            "TextArea.selectionBackground", SelectionBackgroundColor,
-            "TextArea.selectionForeground", SelectionTextColor,
-            "TextArea.caretForeground", WindowTextColor,
-
-            // *** TextField
-            "TextField.font", ControlFont,
-            "TextField.background", TextBackground,
-            "TextField.foreground", WindowTextColor,
-            "TextField.shadow", ControlShadowColor,
-            "TextField.darkShadow", ControlDarkShadowColor,
-            "TextField.light", ControlLightColor,
-            "TextField.highlight", ControlHighlightColor,
-            "TextField.inactiveForeground", InactiveTextColor,      // for disabled
-            "TextField.inactiveBackground", ReadOnlyTextBackground, // for readonly
-            "TextField.disabledBackground", DisabledTextBackground, // for disabled
-            "TextField.selectionBackground", SelectionBackgroundColor,
-            "TextField.selectionForeground", SelectionTextColor,
-            "TextField.caretForeground", WindowTextColor,
-
-            // *** TextPane
-            "TextPane.font", ControlFont,
-            "TextPane.background", WindowBackgroundColor,
-            "TextPane.foreground", WindowTextColor,
-            "TextPane.selectionBackground", SelectionBackgroundColor,
-            "TextPane.selectionForeground", SelectionTextColor,
-            "TextPane.inactiveBackground", WindowBackgroundColor,
-            "TextPane.disabledBackground", DisabledTextBackground,
-            "TextPane.caretForeground", WindowTextColor,
-
-            // *** TitledBorder
-            "TitledBorder.font", ControlFont,
-            "TitledBorder.titleColor",
-                        new XPColorValue(Part.BP_GROUPBOX, null, Prop.TEXTCOLOR,
-                                         WindowTextColor),
-
-            // *** ToggleButton
-            "ToggleButton.font", ControlFont,
-            "ToggleButton.background", ControlBackgroundColor,
-            "ToggleButton.foreground", ControlTextColor,
-            "ToggleButton.shadow", ControlShadowColor,
-            "ToggleButton.darkShadow", ControlDarkShadowColor,
-            "ToggleButton.light", ControlLightColor,
-            "ToggleButton.highlight", ControlHighlightColor,
-            "ToggleButton.focus", ControlTextColor,
-            "ToggleButton.textShiftOffset", Integer.valueOf(1),
-            "ToggleButton.focusInputMap",
-              new UIDefaults.LazyInputMap(new Object[] {
-                            "SPACE", "pressed",
-                   "released SPACE", "released"
-                }),
-
-            // *** ToolBar
-            "ToolBar.font", MenuFont,
-            "ToolBar.background", ControlBackgroundColor,
-            "ToolBar.foreground", ControlTextColor,
-            "ToolBar.shadow", ControlShadowColor,
-            "ToolBar.darkShadow", ControlDarkShadowColor,
-            "ToolBar.light", ControlLightColor,
-            "ToolBar.highlight", ControlHighlightColor,
-            "ToolBar.dockingBackground", ControlBackgroundColor,
-            "ToolBar.dockingForeground", red,
-            "ToolBar.floatingBackground", ControlBackgroundColor,
-            "ToolBar.floatingForeground", darkGray,
-            "ToolBar.ancestorInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                        "UP", "navigateUp",
-                     "KP_UP", "navigateUp",
-                      "DOWN", "navigateDown",
-                   "KP_DOWN", "navigateDown",
-                      "LEFT", "navigateLeft",
-                   "KP_LEFT", "navigateLeft",
-                     "RIGHT", "navigateRight",
-                  "KP_RIGHT", "navigateRight"
-                 }),
-            "ToolBar.separatorSize", null,
-
-            // *** ToolTip
-            "ToolTip.font", ToolTipFont,
-            "ToolTip.background", new WindowsDesktopProperty("win.tooltip.backgroundColor", table.get("info")),
-            "ToolTip.foreground", new WindowsDesktopProperty("win.tooltip.textColor", table.get("infoText")),
-
-        // *** ToolTipManager
-            "ToolTipManager.enableToolTipMode", "activeApplication",
-
-        // *** Tree
-            "Tree.selectionBorderColor", black,
-            "Tree.drawDashedFocusIndicator", Boolean.TRUE,
-            "Tree.lineTypeDashed", Boolean.TRUE,
-            "Tree.font", ControlFont,
-            "Tree.background", WindowBackgroundColor,
-            "Tree.foreground", WindowTextColor,
-            "Tree.hash", gray,
-            "Tree.leftChildIndent", Integer.valueOf(8),
-            "Tree.rightChildIndent", Integer.valueOf(11),
-            "Tree.textForeground", WindowTextColor,
-            "Tree.textBackground", WindowBackgroundColor,
-            "Tree.selectionForeground", SelectionTextColor,
-            "Tree.selectionBackground", SelectionBackgroundColor,
-            "Tree.expandedIcon", treeExpandedIcon,
-            "Tree.collapsedIcon", treeCollapsedIcon,
-            "Tree.openIcon",   new ActiveWindowsIcon("win.icon.shellIconBPP",
-                                   "shell32Icon 5", "icons/TreeOpen.gif"),
-            "Tree.closedIcon", new ActiveWindowsIcon("win.icon.shellIconBPP",
-                                   "shell32Icon 4", "icons/TreeClosed.gif"),
-            "Tree.focusInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                                    "ADD", "expand",
-                               "SUBTRACT", "collapse",
-                                 "ctrl C", "copy",
-                                 "ctrl V", "paste",
-                                 "ctrl X", "cut",
-                                   "COPY", "copy",
-                                  "PASTE", "paste",
-                                    "CUT", "cut",
-                         "control INSERT", "copy",
-                           "shift INSERT", "paste",
-                           "shift DELETE", "cut",
-                                     "UP", "selectPrevious",
-                                  "KP_UP", "selectPrevious",
-                               "shift UP", "selectPreviousExtendSelection",
-                            "shift KP_UP", "selectPreviousExtendSelection",
-                          "ctrl shift UP", "selectPreviousExtendSelection",
-                       "ctrl shift KP_UP", "selectPreviousExtendSelection",
-                                "ctrl UP", "selectPreviousChangeLead",
-                             "ctrl KP_UP", "selectPreviousChangeLead",
-                                   "DOWN", "selectNext",
-                                "KP_DOWN", "selectNext",
-                             "shift DOWN", "selectNextExtendSelection",
-                          "shift KP_DOWN", "selectNextExtendSelection",
-                        "ctrl shift DOWN", "selectNextExtendSelection",
-                     "ctrl shift KP_DOWN", "selectNextExtendSelection",
-                              "ctrl DOWN", "selectNextChangeLead",
-                           "ctrl KP_DOWN", "selectNextChangeLead",
-                                  "RIGHT", "selectChild",
-                               "KP_RIGHT", "selectChild",
-                                   "LEFT", "selectParent",
-                                "KP_LEFT", "selectParent",
-                                "PAGE_UP", "scrollUpChangeSelection",
-                          "shift PAGE_UP", "scrollUpExtendSelection",
-                     "ctrl shift PAGE_UP", "scrollUpExtendSelection",
-                           "ctrl PAGE_UP", "scrollUpChangeLead",
-                              "PAGE_DOWN", "scrollDownChangeSelection",
-                        "shift PAGE_DOWN", "scrollDownExtendSelection",
-                   "ctrl shift PAGE_DOWN", "scrollDownExtendSelection",
-                         "ctrl PAGE_DOWN", "scrollDownChangeLead",
-                                   "HOME", "selectFirst",
-                             "shift HOME", "selectFirstExtendSelection",
-                        "ctrl shift HOME", "selectFirstExtendSelection",
-                              "ctrl HOME", "selectFirstChangeLead",
-                                    "END", "selectLast",
-                              "shift END", "selectLastExtendSelection",
-                         "ctrl shift END", "selectLastExtendSelection",
-                               "ctrl END", "selectLastChangeLead",
-                                     "F2", "startEditing",
-                                 "ctrl A", "selectAll",
-                             "ctrl SLASH", "selectAll",
-                        "ctrl BACK_SLASH", "clearSelection",
-                              "ctrl LEFT", "scrollLeft",
-                           "ctrl KP_LEFT", "scrollLeft",
-                             "ctrl RIGHT", "scrollRight",
-                          "ctrl KP_RIGHT", "scrollRight",
-                                  "SPACE", "addToSelection",
-                             "ctrl SPACE", "toggleAndAnchor",
-                            "shift SPACE", "extendTo",
-                       "ctrl shift SPACE", "moveSelectionTo"
-                 }),
-            "Tree.ancestorInputMap",
-               new UIDefaults.LazyInputMap(new Object[] {
-                     "ESCAPE", "cancel"
-                 }),
-
-            // *** Viewport
-            "Viewport.font", ControlFont,
-            "Viewport.background", ControlBackgroundColor,
-            "Viewport.foreground", WindowTextColor,
-
-
-        };
-
-        table.putDefaults(defaults);
-        table.putDefaults(getLazyValueDefaults());
-        initVistaComponentDefaults(table);
-    }
-
-    static boolean isOnVista() {
-        return OSInfo.getOSType() == OSInfo.OSType.WINDOWS
-                && OSInfo.getWindowsVersion().compareTo(OSInfo.WINDOWS_VISTA) >= 0;
-    }
-
-    static boolean isOnWindows7() {
-        return OSInfo.getOSType() == OSInfo.OSType.WINDOWS
-                && OSInfo.getWindowsVersion().compareTo(OSInfo.WINDOWS_7) >= 0;
-    }
-
-    private void initVistaComponentDefaults(UIDefaults table) {
-        if (! isOnVista()) {
-            return;
-        }
-        /* START handling menus for Vista */
-        String[] menuClasses = { "MenuItem", "Menu",
-                "CheckBoxMenuItem", "RadioButtonMenuItem",
-        };
-
-        Object menuDefaults[] = new Object[menuClasses.length * 2];
-
-        /* all the menus need to be non opaque. */
-        for (int i = 0, j = 0; i < menuClasses.length; i++) {
-            String key = menuClasses[i] + ".opaque";
-            Object oldValue = table.get(key);
-            menuDefaults[j++] = key;
-            menuDefaults[j++] =
-                new XPValue(Boolean.FALSE, oldValue);
-        }
-        table.putDefaults(menuDefaults);
-
-        /*
-         * acceleratorSelectionForeground color is the same as
-         * acceleratorForeground
-         */
-        for (int i = 0, j = 0; i < menuClasses.length; i++) {
-            String key = menuClasses[i] + ".acceleratorSelectionForeground";
-            Object oldValue = table.get(key);
-            menuDefaults[j++] = key;
-            menuDefaults[j++] =
-                new XPValue(
-                    table.getColor(
-                        menuClasses[i] + ".acceleratorForeground"),
-                        oldValue);
-        }
-        table.putDefaults(menuDefaults);
-
-        /* they have the same MenuItemCheckIconFactory */
-        VistaMenuItemCheckIconFactory menuItemCheckIconFactory =
-            WindowsIconFactory.getMenuItemCheckIconFactory();
-        for (int i = 0, j = 0; i < menuClasses.length; i++) {
-            String key = menuClasses[i] + ".checkIconFactory";
-            Object oldValue = table.get(key);
-            menuDefaults[j++] = key;
-            menuDefaults[j++] =
-                new XPValue(menuItemCheckIconFactory, oldValue);
-        }
-        table.putDefaults(menuDefaults);
-
-        for (int i = 0, j = 0; i < menuClasses.length; i++) {
-            String key = menuClasses[i] + ".checkIcon";
-            Object oldValue = table.get(key);
-            menuDefaults[j++] = key;
-            menuDefaults[j++] =
-                new XPValue(menuItemCheckIconFactory.getIcon(menuClasses[i]),
-                    oldValue);
-        }
-        table.putDefaults(menuDefaults);
-
-
-        /* height can be even */
-        for (int i = 0, j = 0; i < menuClasses.length; i++) {
-            String key = menuClasses[i] + ".evenHeight";
-            Object oldValue = table.get(key);
-            menuDefaults[j++] = key;
-            menuDefaults[j++] = new XPValue(Boolean.TRUE, oldValue);
-        }
-        table.putDefaults(menuDefaults);
-
-        /*For Windows7 margin and checkIconOffset should be greater than 0 */
-        if (!isOnWindows7()) {
-            /* no margins */
-            InsetsUIResource insets = new InsetsUIResource(0, 0, 0, 0);
-            for (int i = 0, j = 0; i < menuClasses.length; i++) {
-                String key = menuClasses[i] + ".margin";
-                Object oldValue = table.get(key);
-                menuDefaults[j++] = key;
-                menuDefaults[j++] = new XPValue(insets, oldValue);
-            }
-            table.putDefaults(menuDefaults);
-
-            /* set checkIcon offset */
-            Integer checkIconOffsetInteger =
-                Integer.valueOf(0);
-            for (int i = 0, j = 0; i < menuClasses.length; i++) {
-                String key = menuClasses[i] + ".checkIconOffset";
-                Object oldValue = table.get(key);
-                menuDefaults[j++] = key;
-                menuDefaults[j++] =
-                    new XPValue(checkIconOffsetInteger, oldValue);
-            }
-            table.putDefaults(menuDefaults);
-        }
-        /* set width of the gap after check icon */
-        Integer afterCheckIconGap = WindowsPopupMenuUI.getSpanBeforeGutter()
-                + WindowsPopupMenuUI.getGutterWidth()
-                + WindowsPopupMenuUI.getSpanAfterGutter();
-        for (int i = 0, j = 0; i < menuClasses.length; i++) {
-            String key = menuClasses[i] + ".afterCheckIconGap";
-            Object oldValue = table.get(key);
-            menuDefaults[j++] = key;
-            menuDefaults[j++] =
-                new XPValue(afterCheckIconGap, oldValue);
-        }
-        table.putDefaults(menuDefaults);
-
-        /* text is started after this position */
-        Object minimumTextOffset = new UIDefaults.ActiveValue() {
-            public Object createValue(UIDefaults table) {
-                return VistaMenuItemCheckIconFactory.getIconWidth()
-                + WindowsPopupMenuUI.getSpanBeforeGutter()
-                + WindowsPopupMenuUI.getGutterWidth()
-                + WindowsPopupMenuUI.getSpanAfterGutter();
-            }
-        };
-        for (int i = 0, j = 0; i < menuClasses.length; i++) {
-            String key = menuClasses[i] + ".minimumTextOffset";
-            Object oldValue = table.get(key);
-            menuDefaults[j++] = key;
-            menuDefaults[j++] = new XPValue(minimumTextOffset, oldValue);
-        }
-        table.putDefaults(menuDefaults);
-
-        /*
-         * JPopupMenu has a bit of free space around menu items
-         */
-        String POPUP_MENU_BORDER = "PopupMenu.border";
-
-        Object popupMenuBorder = new XPBorderValue(Part.MENU,
-            (LazyValue) t -> BasicBorders.getInternalFrameBorder(),
-                  BorderFactory.createEmptyBorder(2, 2, 2, 2));
-        table.put(POPUP_MENU_BORDER, popupMenuBorder);
-        /* END handling menus for Vista */
-
-        /* START table handling for Vista */
-        table.put("Table.ascendingSortIcon", new XPValue(
-            new SkinIcon(Part.HP_HEADERSORTARROW, State.SORTEDDOWN),
-               (LazyValue) t -> new ClassicSortArrowIcon(true)));
-        table.put("Table.descendingSortIcon", new XPValue(
-            new SkinIcon(Part.HP_HEADERSORTARROW, State.SORTEDUP),
-               (LazyValue) t -> new ClassicSortArrowIcon(false)));
-        /* END table handling for Vista */
-    }
-
-    /**
-     * If we support loading of fonts from the desktop this will return
-     * a WindowsDesktopProperty representing the font. If the font can't be
-     * represented in the current encoding this will return null and
-     * turn off the use of system fonts.
-     */
-    private Object getDesktopFontValue(String fontName, Object backup) {
-        if (useSystemFontSettings) {
-            return new WindowsFontProperty(fontName, backup);
-        }
-        return null;
-    }
-
-    // When a desktop property change is detected, these classes must be
-    // reinitialized in the defaults table to ensure the classes reference
-    // the updated desktop property values (colors mostly)
-    //
-    private Object[] getLazyValueDefaults() {
-
-        Object buttonBorder =
-            new XPBorderValue(Part.BP_PUSHBUTTON,
-               (LazyValue) t -> BasicBorders.getButtonBorder());
-
-        Object textFieldBorder =
-            new XPBorderValue(Part.EP_EDIT,
-               (LazyValue) t -> BasicBorders.getTextFieldBorder());
-
-        Object textFieldMargin =
-            new XPValue(new InsetsUIResource(2, 2, 2, 2),
-                        new InsetsUIResource(1, 1, 1, 1));
-
-        Object spinnerBorder =
-            new XPBorderValue(Part.EP_EDIT, textFieldBorder,
-                              new EmptyBorder(2, 2, 2, 2));
-
-        Object spinnerArrowInsets =
-            new XPValue(new InsetsUIResource(1, 1, 1, 1),
-                        null);
-
-        Object comboBoxBorder = new XPBorderValue(Part.CP_COMBOBOX, textFieldBorder);
-
-        // For focus rectangle for cells and trees.
-        LazyValue focusCellHighlightBorder = t -> WindowsBorders.getFocusCellHighlightBorder();
-
-        LazyValue etchedBorder = t -> BorderUIResource.getEtchedBorderUIResource();
-
-        LazyValue internalFrameBorder = t -> WindowsBorders.getInternalFrameBorder();
-
-        LazyValue loweredBevelBorder = t -> BorderUIResource.getLoweredBevelBorderUIResource();
-
-
-        LazyValue marginBorder = t -> new BasicBorders.MarginBorder();
-
-        LazyValue menuBarBorder = t -> BasicBorders.getMenuBarBorder();
-
-
-        Object popupMenuBorder = new XPBorderValue(Part.MENU,
-            (LazyValue) t -> BasicBorders.getInternalFrameBorder());
-
-        // *** ProgressBar
-        LazyValue progressBarBorder = t -> WindowsBorders.getProgressBarBorder();
-
-        LazyValue radioButtonBorder = t -> BasicBorders.getRadioButtonBorder();
-
-        Object scrollPaneBorder =
-            new XPBorderValue(Part.LBP_LISTBOX, textFieldBorder);
-
-        Object tableScrollPaneBorder =
-            new XPBorderValue(Part.LBP_LISTBOX, loweredBevelBorder);
-
-        LazyValue tableHeaderBorder = t -> WindowsBorders.getTableHeaderBorder();
-
-        // *** ToolBar
-        LazyValue toolBarBorder = t -> WindowsBorders.getToolBarBorder();
-
-        // *** ToolTips
-        LazyValue toolTipBorder = t -> BorderUIResource.getBlackLineBorderUIResource();
-
-
-
-        LazyValue checkBoxIcon = t -> WindowsIconFactory.getCheckBoxIcon();
-
-        LazyValue radioButtonIcon = t -> WindowsIconFactory.getRadioButtonIcon();
-
-        LazyValue radioButtonMenuItemIcon = t -> WindowsIconFactory.getRadioButtonMenuItemIcon();
-
-        LazyValue menuItemCheckIcon = t -> WindowsIconFactory.getMenuItemCheckIcon();
-
-        LazyValue menuItemArrowIcon = t -> WindowsIconFactory.getMenuItemArrowIcon();
-
-        LazyValue menuArrowIcon = t -> WindowsIconFactory.getMenuArrowIcon();
-
-        Color highlight = (Color) Toolkit.getDefaultToolkit().
-                getDesktopProperty("win.3d.highlightColor");
-
-        Color shadow = (Color) Toolkit.getDefaultToolkit().
-                getDesktopProperty("win.3d.shadowColor");
-
-        Object[] lazyDefaults = {
-            "Button.border", buttonBorder,
-            "CheckBox.border", radioButtonBorder,
-            "ComboBox.border", comboBoxBorder,
-            "DesktopIcon.border", internalFrameBorder,
-            "FormattedTextField.border", textFieldBorder,
-            "FormattedTextField.margin", textFieldMargin,
-            "InternalFrame.border", internalFrameBorder,
-            "List.focusCellHighlightBorder", focusCellHighlightBorder,
-            "Table.focusCellHighlightBorder", focusCellHighlightBorder,
-            "Menu.border", marginBorder,
-            "MenuBar.border", menuBarBorder,
-            "MenuItem.border", marginBorder,
-            "PasswordField.border", textFieldBorder,
-            "PasswordField.margin", textFieldMargin,
-            "PopupMenu.border", popupMenuBorder,
-            "ProgressBar.border", progressBarBorder,
-            "RadioButton.border", radioButtonBorder,
-            "ScrollPane.border", scrollPaneBorder,
-            "Spinner.border", spinnerBorder,
-            "Spinner.arrowButtonInsets", spinnerArrowInsets,
-            "Spinner.arrowButtonSize", new Dimension(17, 9),
-            "Table.scrollPaneBorder", tableScrollPaneBorder,
-            "TableHeader.cellBorder", tableHeaderBorder,
-            "TextArea.margin", textFieldMargin,
-            "TextField.border", textFieldBorder,
-            "TextField.margin", textFieldMargin,
-            "TitledBorder.border", new UIDefaults.LazyValue() {
-                public Object createValue(UIDefaults table) {
-                    return new BorderUIResource.
-                            EtchedBorderUIResource(highlight, shadow);
-                }
-            },
-            "ToggleButton.border", radioButtonBorder,
-            "ToolBar.border", toolBarBorder,
-            "ToolTip.border", toolTipBorder,
-
-            "CheckBox.icon", checkBoxIcon,
-            "Menu.arrowIcon", menuArrowIcon,
-            "MenuItem.checkIcon", menuItemCheckIcon,
-            "MenuItem.arrowIcon", menuItemArrowIcon,
-            "RadioButton.icon", radioButtonIcon,
-            "RadioButtonMenuItem.checkIcon", radioButtonMenuItemIcon,
-            "InternalFrame.layoutTitlePaneAtOrigin",
-                        new XPValue(Boolean.TRUE, Boolean.FALSE),
-            "Table.ascendingSortIcon", new XPValue(
-               (LazyValue) t -> new SortArrowIcon(true,"Table.sortIconColor"),
-                  (LazyValue) t -> new ClassicSortArrowIcon(true)),
-            "Table.descendingSortIcon", new XPValue(
-               (LazyValue) t -> new SortArrowIcon(false,"Table.sortIconColor"),
-                  (LazyValue) t -> new ClassicSortArrowIcon(false)),
-        };
-
-        return lazyDefaults;
-    }
-
-    public void uninitialize() {
-        super.uninitialize();
-
-        if (WindowsPopupMenuUI.mnemonicListener != null) {
-            MenuSelectionManager.defaultManager().
-                removeChangeListener(WindowsPopupMenuUI.mnemonicListener);
-        }
-        KeyboardFocusManager.getCurrentKeyboardFocusManager().
-            removeKeyEventPostProcessor(WindowsRootPaneUI.altProcessor);
-        WindowsDesktopProperty.flushUnreferencedProperties();
-    }
-
-
-    // Toggle flag for drawing the mnemonic state
-    private static boolean isMnemonicHidden = true;
-
-    // Flag which indicates that the Win98/Win2k/WinME features
-    // should be disabled.
-    private static boolean isClassicWindows = false;
-
-    /**
-     * Sets the state of the hide mnemonic flag. This flag is used by the
-     * component UI delegates to determine if the mnemonic should be rendered.
-     * This method is a non operation if the underlying operating system
-     * does not support the mnemonic hiding feature.
-     *
-     * @param hide true if mnemonics should be hidden
-     * @since 1.4
-     */
-    public static void setMnemonicHidden(boolean hide) {
-        if (UIManager.getBoolean("Button.showMnemonics") == true) {
-            // Do not hide mnemonics if the UI defaults do not support this
-            isMnemonicHidden = false;
-        } else {
-            isMnemonicHidden = hide;
-        }
-    }
-
-    /**
-     * Gets the state of the hide mnemonic flag. This only has meaning
-     * if this feature is supported by the underlying OS.
-     *
-     * @return true if mnemonics are hidden, otherwise, false
-     * @see #setMnemonicHidden
-     * @since 1.4
-     */
-    public static boolean isMnemonicHidden() {
-        if (UIManager.getBoolean("Button.showMnemonics") == true) {
-            // Do not hide mnemonics if the UI defaults do not support this
-            isMnemonicHidden = false;
-        }
-        return isMnemonicHidden;
-    }
-
-    /**
-     * Gets the state of the flag which indicates if the old Windows
-     * look and feel should be rendered. This flag is used by the
-     * component UI delegates as a hint to determine which style the component
-     * should be rendered.
-     *
-     * @return true if Windows 95 and Windows NT 4 look and feel should
-     *         be rendered
-     * @since 1.4
-     */
-    public static boolean isClassicWindows() {
-        return isClassicWindows;
-    }
-
-    /**
-     * <p>
-     * Invoked when the user attempts an invalid operation,
-     * such as pasting into an uneditable <code>JTextField</code>
-     * that has focus.
-     * </p>
-     * <p>
-     * If the user has enabled visual error indication on
-     * the desktop, this method will flash the caption bar
-     * of the active window. The user can also set the
-     * property awt.visualbell=true to achieve the same
-     * results.
-     * </p>
-     *
-     * @param component Component the error occurred in, may be
-     *                  null indicating the error condition is
-     *                  not directly associated with a
-     *                  <code>Component</code>.
-     *
-     * @see javax.swing.LookAndFeel#provideErrorFeedback
-     */
-     public void provideErrorFeedback(Component component) {
-         super.provideErrorFeedback(component);
-     }
-
-    /**
-     * {@inheritDoc}
-     */
-    public LayoutStyle getLayoutStyle() {
-        LayoutStyle style = this.style;
-        if (style == null) {
-            style = new WindowsLayoutStyle();
-            this.style = style;
-        }
-        return style;
-    }
-
-    // ********* Auditory Cue support methods and objects *********
-
-    /**
-     * Returns an <code>Action</code>.
-     * <P>
-     * This Action contains the information and logic to render an
-     * auditory cue. The <code>Object</code> that is passed to this
-     * method contains the information needed to render the auditory
-     * cue. Normally, this <code>Object</code> is a <code>String</code>
-     * that points to a <code>Toolkit</code> <code>desktopProperty</code>.
-     * This <code>desktopProperty</code> is resolved by AWT and the
-     * Windows OS.
-     * <P>
-     * This <code>Action</code>'s <code>actionPerformed</code> method
-     * is fired by the <code>playSound</code> method.
-     *
-     * @return      an Action which knows how to render the auditory
-     *              cue for one particular system or user activity
-     * @see #playSound(Action)
-     * @since 1.4
-     */
-    protected Action createAudioAction(Object key) {
-        if (key != null) {
-            String audioKey = (String)key;
-            String audioValue = (String)UIManager.get(key);
-            return new AudioAction(audioKey, audioValue);
-        } else {
-            return null;
-        }
-    }
-
-    static void repaintRootPane(Component c) {
-        JRootPane root = null;
-        for (; c != null; c = c.getParent()) {
-            if (c instanceof JRootPane) {
-                root = (JRootPane)c;
-            }
-        }
-
-        if (root != null) {
-            root.repaint();
-        } else {
-            c.repaint();
-        }
-    }
-
-    /**
-     * Pass the name String to the super constructor. This is used
-     * later to identify the Action and decide whether to play it or
-     * not. Store the resource String. It is used to get the audio
-     * resource. In this case, the resource is a <code>Runnable</code>
-     * supplied by <code>Toolkit</code>. This <code>Runnable</code> is
-     * effectively a pointer d