|Bring shell to top of desktop programmatically [message #666156]
||Tue, 19 April 2011 11:19
| Artur Kronenberg
Registered: August 2009
I am using my trayicon to hide and show my application. If the application is invisible and I click on it, my call to setVisible(true) will bring the application to the front (not only of other SWT apps but of everything that is on my desktop).
If I minimize the app and it is in the task bar and I call setVisible(true) it won't bring the shell up. Same problem, if another window is hiding my shell.
I would like to be able to bring the application to the front always, no matter if it is currently invisible, minimized or hidden behind different windows.
In the Shell#setVisible() code there are several events to GTK dispatched but the documentation tells me, that I am not supposed to reuse them if my shell is visible.
I don't want to set my shell inivisible and then call open every time I click on my tray Icon, because it will disappear and reappear if it already was at the top.
Is there another way to achieve this?
Powered by FUDForum
. Page generated in 0.01368 seconds