<AWT Dev> RFR: 8252015: [macos11] java.awt.TrayIcon requires updates for template images
Sergey Bylokhov
serb at openjdk.java.net
Mon Nov 30 04:55:00 UTC 2020
On Thu, 26 Nov 2020 07:58:59 GMT, Peter Zhelezniakov <peterz at openjdk.org> wrote:
>> Hi Sergey, and thanks for looking into this!
>>
>> Try the attached jar, it's a modified version of TrayIconDemo using a template icon taken from Wikimedia Commons. Without the fix, or without `-Dsun.awt.enableTemplateImages`, the icon disappears if you switch to Dark theme. With the fix and the property set, the system repaints it in white.
>>
>> [TrayIconDemo.jar.zip](https://github.com/openjdk/jdk/files/5332241/TrayIconDemo.jar.zip)
>
> Filed [CSR request](https://bugs.openjdk.java.net/browse/JDK-8255597)
Please check the tests in the .../test/jdk/java/awt/TrayIcon/ folder it looks like some of them fail after the fix:
java/awt/TrayIcon/ActionCommand/ActionCommand.java
java/awt/TrayIcon/ActionEventMask/ActionEventMask.java
java/awt/TrayIcon/MouseEventMask/MouseEventMaskTest.java
java/awt/TrayIcon/SecurityCheck/FunctionalityCheck/FunctionalityCheck.java
java/awt/TrayIcon/TrayIconEventModifiers/TrayIconEventModifiersTest.java
java/awt/TrayIcon/TrayIconEvents/TrayIconEventsTest.java
java/awt/TrayIcon/TrayIconMouseTest/TrayIconMouseTest.java
java/awt/TrayIcon/TrayIconPopup/TrayIconPopupTest.java
-------------
PR: https://git.openjdk.java.net/jdk/pull/481
More information about the awt-dev
mailing list