src/share/classes/com/sun/java/swing/plaf/windows/WindowsPopupMenuUI.java

Print this page

        

*** 1,7 **** /* ! * 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 --- 1,7 ---- /* ! * 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
*** 192,203 **** return leftToRight; } @Override public void paint(Graphics g, JComponent c) { - if (WindowsMenuItemUI.isVistaPainting()) { XPStyle xp = XPStyle.getXP(); Skin skin = xp.getSkin(c, Part.MP_POPUPBACKGROUND); skin.paintSkin(g, 0, 0, c.getWidth(),c.getHeight(), State.NORMAL); int textOffset = getTextOffset(c); if (textOffset >= 0 /* paint gutter only for leftToRight case */ --- 192,203 ---- return leftToRight; } @Override public void paint(Graphics g, JComponent c) { XPStyle xp = XPStyle.getXP(); + if (WindowsMenuItemUI.isVistaPainting(xp)) { Skin skin = xp.getSkin(c, Part.MP_POPUPBACKGROUND); skin.paintSkin(g, 0, 0, c.getWidth(),c.getHeight(), State.NORMAL); int textOffset = getTextOffset(c); if (textOffset >= 0 /* paint gutter only for leftToRight case */