RFR: 8286663: Resolve IDE warnings in WTrayIconPeer and SystemTray

Alexey Ivanov aivanov at openjdk.java.net
Mon May 23 16:50:13 UTC 2022


**WTrayIconPeer**: removed duplicate call to `popupParent.dispose()` that might cause NPE (it looks `popupParent` cannot be `null`); organised imports.

**SystemTray**: removed redundant initialisers; replaced sized array with empty array in `toArray` call; dropped `newValue != null` chained with `equals`.

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

Commit messages:
 - Resolve IDE warnings: redundant initializer, sized array in toArray
 - Remove 2nd call to popupParent.dispose()

Changes: https://git.openjdk.java.net/jdk/pull/8850/files
 Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=8850&range=00
  Issue: https://bugs.openjdk.java.net/browse/JDK-8286663
  Stats: 20 lines in 2 files changed: 8 ins; 4 del; 8 mod
  Patch: https://git.openjdk.java.net/jdk/pull/8850.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/8850/head:pull/8850

PR: https://git.openjdk.java.net/jdk/pull/8850



More information about the client-libs-dev mailing list