简体   繁体   中英

How to pin my SWT app in the windows taskbar

The title pretty much says everything.

I have the icon in the taskbar but when I right click it i can only "close the window".

It might have something to do with AppUserModelID , which is related to my first line of code when the program starts : Display.setAppName("MYAPPNAME"); I'm aware that there is a TaskBar class which I already use for progress / icon edit / menu ( not working on Win ) but there's nothing about pining.

edit : I use launch4j to launch my app.

Thanks

Only executables can be pinned to the taskbar. A jar file is per se no executable. You can do the following to pin your application:

  1. Use a tool like install4j to create an installer and executable of your application
  2. Use the answer to this question

If you're running it directly from an IDE, there is no way (that I know of) to pin it.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM