RE: Win32 API HInstance and gtk+ - how?



The normal way to get the app instance is to do GetWindowLong (hwnd,
GWL_HINSTANCE)
But hInstance and prevInstance aren't very useful these days, they
cannot be used to check if a program is already running as it could be
on Win-16.

The normal way is to do that is to use FindWindow with the window class
and Window name as NULL.

> -----Original Message-----
> From: gtk-list-bounces gnome org 
> [mailto:gtk-list-bounces gnome org] On Behalf Of Tor Lillqvist
> Sent: 12 December 2005 09:34
> To: Igor Gorbounov
> Cc: gtk-list; GTKMM Lists
> Subject: Win32 API HInstance and gtk+ - how?
> 
> Igor Gorbounov writes:
>  > Tell me, please, if there is any way to get a Win API 
> application  > instance handle in a gtkmm application
> 
> GetModuleHandle(NULL) ? 
> 
> (I think "application instance" is Windows 3.x terminology, but the
> MCIWndCreate() docs say "handle to the module", to presumably
> GetModuleHandle() is what you want.
> 
> --tml
> 
> _______________________________________________
> gtk-list mailing list
> gtk-list gnome org
> http://mail.gnome.org/mailman/listinfo/gtk-list
> 



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