I have an app where I use a notifyicon to show some balloon tips. However, it will be running in an environment where there is always a separate main app running in full-screen mode. My problem is making the taskbar come to front – I thought it would automatically when there are balloon tips appearing on the notifyicon in the system tray.
Can I make the taskbar become visible over the app running in full-screen mode?
I have tried the following but it’s not a case of hiding or unhiding the taskbar – it’s a case of bringing it to the front or making the running app not full-screen…
int TaskBarHwnd = FindWindow("Shell_traywnd", "");
bool result1 = SetWindowPos(TaskBarHwnd, 0, 0, 0, 0, 0, SWP_HIDEWINDOW); // Hide Taskbar
bool result1 = SetWindowPos(TaskBarHwnd, 0, 0, 0, 0, 0, SWP_SHOWWINDOW); // Show Taskbar
EDIT
There must be a way of doing this – if I am watching a movie and my battery is low then the taskbar slides up and I get a notification about the battery. I need to find out what the OS does to get this behaviour…
EDIT
It is worth saying that the sourcecode for the fullscreen app is under our control. This does change the question in fairness but I would still like to know a way of “interrupting” a fullscreen app regardless of whether you have control or not.
One way I’m looking at doing it now is by sending the escape key from my notifyicon app.
This works as the standard behaviour for a fullscreen app is usually to exit the fullscreen mode when escape is hit on the keyboard. I still don’t think this is the best solution because there may be times when forcing an ESC might have side effects if the user is doing something else…but it may well be “just good enough”