win32: get notified when gtk+ app gets killed?
- From: "fkater googlemail com" <fkater googlemail com>
- To: gtk-app-devel-list gnome org
- Subject: win32: get notified when gtk+ app gets killed?
- Date: Mon, 8 Dec 2008 22:42:34 +0100
Hi all,
on win32, in some situations (like logoff, shutdown) my gtk+
app gets killed, so I do not receive the standard gtk+ window
close/destroy signals and, in turn, cannot do clean up tasks.
For a console (!) app I've found SetConsoleCtrlHandler()
which works surprisingly well (one can set up a callback for
all interesting situations).
However, for non-console apps (with -mwindows) this does not
work.
I tried MS Window's signal() function, but it knows SIGTERM
only, not SIGKILL. No way here.
For non-console apps, MSDN says I need to set up a
WindowProc callback to catch WM_QUERYENDSESSION messages.
But to register it, it seems I need hWnd from the main
window which is somewhere hidden by gtk+...
So, is there a way to get notified somehow?
Thanks for any hint!
Felix
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]