How to tell the difference between a minimize and a switch desktop?

Hi All,
I'm trying to write a program that will minimize to a tray icon. I do
this by writing a handler for the "window-state-event", and checking
the "changed mask" and "new window state" for the
GDK_WINDOW_STATE_ICONIFIED flag. It all works well, and I also add a
handler for the "activate" callback of the status icon to bring the
window back.

However, it seems like my "window-state-event" handler is getting
called when I switch desktops. Is there some way to detect this? I'm
using the default Gnome setup with Fedora 9, not using compiz.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]