• Post Reply Bookmark Topic Watch Topic
  • New Topic

create system tray  RSS feed

 
sathya rajavel
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

i want to create system tray
while clicking the system tray it should open a frame for login
 
Rob Spoor
Sheriff
Posts: 21050
85
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the Ranch!

Check out SystemTray and TrayIcon. The latter can have an ActionListener or a MouseListener added to it to listen for click events; I believe that ActionListener is usually triggered upon double clicking, whereas with MouseListener you have full control over the number of clicks or even the button that was clicked.

You should always check if SystemTray.isSupported() returns true before using it; there's an example on the SystemTray Javadoc page.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!