发布网友 发布时间:2022-04-24 01:39
共1个回答
热心网友 时间:2023-10-19 04:45
age img = tk.getImage("a.png");
SystemTray systemTray = SystemTray.getSystemTray();//获得系统托盘的实例
try
{
trayIcon=new TrayIcon(img,"aaaa");
systemTray.add(trayIcon);//设置托盘的图标,0.gif与该类文件同一目录
}
catch (AWTException e2)
{
e2.printStackTrace();
}
热心网友 时间:2023-10-19 04:45
age img = tk.getImage("a.png");
SystemTray systemTray = SystemTray.getSystemTray();//获得系统托盘的实例
try
{
trayIcon=new TrayIcon(img,"aaaa");
systemTray.add(trayIcon);//设置托盘的图标,0.gif与该类文件同一目录
}
catch (AWTException e2)
{
e2.printStackTrace();
}