RFR: 8316931: [macos14] Test "java/awt/TrayIcon/ShowAfterDisposeTest/ShowAfterDisposeTest.html" throws and exception on Mac OS 14(x64, aarch64) [v9]

Sergey Bylokhov serb at openjdk.org
Thu Feb 1 19:46:07 UTC 2024


On Thu, 1 Feb 2024 16:46:18 GMT, Alisen Chung <achung at openjdk.org> wrote:

>> SunToolkit.java is trying to post an event on the TrayIcon appContext, but the TrayIcon was already removed by the test, causing an error. The fix is to make SunToolkit skip posting the event if appContext is null. The test is also updated to remove applet usage and use PassFailJFrame instead.
>
> Alisen Chung has updated the pull request incrementally with one additional commit since the last revision:
> 
>   remove comment, remove null check in updateNativeImage

src/java.desktop/macosx/classes/sun/lwawt/macosx/CTrayIcon.java line 221:

> 219:                 setNativeImage(ptr, imagePtr, imageAutoSize, useTemplateImages);
> 220:             });
> 221:         });

you deleted the wrong null check, the correct one is below see target == null

src/java.desktop/share/classes/sun/awt/SunToolkit.java line 2:

> 1: /*
> 2:  * Copyright (c) 1997, 2023, Oracle and/or its affiliates. All rights reserved.

This can be discarded.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/17329#discussion_r1475056981
PR Review Comment: https://git.openjdk.org/jdk/pull/17329#discussion_r1475057307


More information about the client-libs-dev mailing list