JDK-6575405 : JTrayIcon class with javax.swing.ImageIcon and JPopupMenu
  • Type: Enhancement
  • Component: client-libs
  • Sub-Component: javax.swing
  • Affected Version: 6
  • Priority: P4
  • Status: Open
  • Resolution: Unresolved
  • OS: windows_xp
  • CPU: x86
  • Submitted: 2007-06-29
  • Updated: 2024-03-25
Related Reports
Duplicate :  
Relates :  
Relates :  
Description
A DESCRIPTION OF THE REQUEST :
The TrayIcon class should have a constructor which takes an java.awt.ImageIcon as an argument. Presently it has a constructor which takes java.awt.Image as argument.

JUSTIFICATION :
As the TrayIcon will display a "Icon" in the SystemTray it makes more sense to have a constructor which takes ImageIcon as an argument. And constructing ImageIcon is much more simpler than constructing an Image.

Comments
EVALUATION as far as I know there is no java.awt.ImageIcon, but we have javax.swing.ImageIcon instead, hope that after that observation it is clear why java.awt.TrayIcon doesn't have requested ctor ;) From the other hand, if/when Swing will develop Swing vesrion of TrayIcon (which should use JPopupMenu) it could also consider adding this ctor to thier JTrayIcon. So reassigning to Swing team.
29-06-2007