<Swing Dev> [8] Review request for 8016551: JMenuItem in WindowsLookAndFeel can't paint default icons
Leonid Romanov
leonid.romanov at oracle.com
Wed Sep 25 14:01:26 UTC 2013
On 9/25/2013 16:37, Sergey Bylokhov wrote:
> On 25.09.2013 16:32, Leonid Romanov wrote:
>> On 9/25/2013 16:09, Sergey Bylokhov wrote:
>>> On 25.09.2013 15:49, Leonid Romanov wrote:
>>>> I'm not sure whether UIManager.getIcon("InternalFrame.closeIcon")
>>>> is guaranteed to return non null with other look&feels.
>>> I am not sure it is guaranteed to wl&f as well. I don't see
>>> specific to windows code.
>>
>> com.sun.java.swing.plaf.windows.WindowsLookAndFeel has the following
>> line in initComponentDefaults() method:
>> "InternalFrame.closeIcon", WindowsIconFactory.createFrameCloseIcon()
>>
>> So I think we can be sure about wl&f.
> The same code exists in aqua, metal etc. But it can be null or can be
> changed to null in future.
My assumption was that the set of UI defaults for a l&f is like a public
API for that l&f, in a sense that once you've added a particular default
you can't simply remove it later because of the backward compatibility.
>>
>>>>
>>>> On Sep 25, 2013, at 1:55 AM, Sergey Bylokhov
>>>> <Sergey.Bylokhov at oracle.com> wrote:
>>>>
>>>>> Hi, Leonid.
>>>>> Is the test not applicable for default l&f if WindowsLookAndFeel
>>>>> is not exists?
>>>>>
>>>>> On 25.09.2013 1:29, Leonid Romanov wrote:
>>>>>> Hello,
>>>>>> Please review a one line fix for 8016551: JMenuItem in
>>>>>> WindowsLookAndFeel can't paint default icons. I'm not sure
>>>>>> whether such a trivial change needs a regression test, but I've
>>>>>> written one anyway, just in case. If it's not needed, I won't
>>>>>> commit it.
>>>>>>
>>>>>> bug: https://bugs.openjdk.java.net/browse/JDK-8016551
>>>>>> webrev: http://cr.openjdk.java.net/~leonidr/8016551/webrev.00/
>>>>>> <http://cr.openjdk.java.net/%7Eleonidr/8016551/webrev.00/>
>>>>>>
>>>>>> Thanks,
>>>>>> Leonid.
>>>>>>
>>>>>
>>>>> --
>>>>> Best regards, Sergey.
>>>>>
>>>
>>>
>>
>
>
More information about the swing-dev
mailing list