RFR: 8286663: Resolve IDE warnings in WTrayIconPeer and SystemTray [v2]

Alexey Ivanov aivanov at openjdk.java.net
Tue May 24 11:20:36 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`.

Alexey Ivanov has updated the pull request incrementally with three additional commits since the last revision:

 - toArray: new TrayIcon[0] -> EMPTY_TRAY_ARRAY - use existing empty array
 - Drop explicit type argument
 - Make popupParent final

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

Changes:
  - all: https://git.openjdk.java.net/jdk/pull/8850/files
  - new: https://git.openjdk.java.net/jdk/pull/8850/files/e2beded7..a2f8c952

Webrevs:
 - full: https://webrevs.openjdk.java.net/?repo=jdk&pr=8850&range=01
 - incr: https://webrevs.openjdk.java.net/?repo=jdk&pr=8850&range=00-01

  Stats: 6 lines in 2 files changed: 0 ins; 2 del; 4 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