Reputation: 31
I am currently developing a Java cross-platform (windows and mac os x) application running in background and displaying a pop-up window on some user's or system's events like "Copy and Paste" or programs' launching.
Nevertheless, I would like to detect first, if any other program, not necessarily developed in Java, is running in full screen mode. In that case, I would not display my window. For instance, when user is watching a movie in full screen (media player...), a Powerpoint presentation...
So here are my questions : 1. Is there any way to do such a thing in Java language? 2. If it's not possible, I will do my "full screen mode detector" in another language but it has to be able to communicate with my Java app to notify the presence of a full screen window. 3. If it's not possible (1) : do you know the best language to do it? I found other solutions in C# or C++ MFC( How to check if an other program is running in fullscreen mode, eg. a media player ).
Any idea would be very useful. Thanks a lot.
Sebastian
Upvotes: 2
Views: 1109
Reputation: 31
Eventually I did one external program for each OS which checks if active window is in full screen mode or not and writes the result on standard output. My Java app calls the good program according to the OS and read the result.
I used :
The hardest part was Mac OS X version.
Don't hesitate to ask me if you're interested in these programs.
Thanks again for your help!
Upvotes: 1
Reputation: 10936
The simplest solution is to give the user the option of enabling/disabling your pop-ups. That way they can pick and choose when to receive pop ups.
Upvotes: 0
Reputation: 2050
You can capture screen with java.awt.Robot, can you implement algorithm based on screenshot?
Upvotes: 0