create Tray Icon - Java java.awt

Java examples for java.awt:TrayIcon

Description

create Tray Icon

Demo Code


//package com.java2s;

import java.awt.Image;

import java.awt.PopupMenu;

import java.awt.TrayIcon;

public class Main {
    public static TrayIcon createTrayIcon(Image img, String tip,
            PopupMenu menu) {//w  w  w  .j  a v  a 2  s. com
        TrayIcon icon = new TrayIcon(img, tip, menu);
        icon.setImageAutoSize(true);
        return icon;
    }
}

Related Tutorials