java – 将程序隐藏在Windows系统托盘中

我想我的程序在
Windows中的时钟附近的TaskBar状态区域中显示一个图标,并找到一种方法.

事情是,如果窗口上按下“X”,而不是在系统托盘中,我希望我的程序在状态区域保持打开状态,但我不知道如何这样做,并且在Google上搜索“帮助(我可能没有搜索正确的词).

编辑:我觉得我用错了条款.我知道如何在通知区域中显示程序的图标,我希望将其隐藏在最小化窗口时通常显示的区域.

解决方法

I know how to have my program’s icon in the notification area,what I’d like is to hide it in the area where it is normally displayed when you minimize a window.

然后不要使用系统托盘.

The thing is,I’d like my program to stay open in the Status Area if the “X” is pressed on the window,

frame.setDefaultCloSEOperation(JFrame.HIDE_ON_CLOSE);

dawei

【声明】:唐山站长网内容转载自互联网,其相关言论仅代表作者个人观点绝非权威,不代表本站立场。如您发现内容存在版权问题,请提交相关链接至邮箱:bqsm@foxmail.com,我们将及时予以处理。