<Swing Dev> Review Request of 8146321: [macosx] JInternalFrame frame icon in wrong position on Mac L&F if icon is not ImageIcon

Sergey Bylokhov Sergey.Bylokhov at oracle.com
Wed Feb 3 15:23:20 UTC 2016


On 02.02.16 15:25, Alexandr Scherbatiy wrote:
>      The provided example  should work with the check: "(icon instanceof
> Icon)" in the same way as with the check "(icon != null && (icon
> instanceof Icon))" because the used icon is not null and it implements
> Icon interface, should not it?

Note that "icon instanceof Icon" in "(icon != null && (icon instanceof 
Icon))" is unnecessary because icon is Icon already. Only null check is 
necessary.

-- 
Best regards, Sergey.



More information about the swing-dev mailing list