From: Emmanuel Puig Date: Tue, 15 Apr 2003 20:54:58 +0000 (+0000) Subject: * GTK2 events work even better X-Git-Tag: 0.6.0~571 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=be0b6cf0679f410d390dfef0d47153b93a8654f1;p=vlc * GTK2 events work even better --- diff --git a/modules/gui/skins/gtk2/gtk2_api.cpp b/modules/gui/skins/gtk2/gtk2_api.cpp index 0efe53c3ea..bfa17b4a6c 100644 --- a/modules/gui/skins/gtk2/gtk2_api.cpp +++ b/modules/gui/skins/gtk2/gtk2_api.cpp @@ -2,7 +2,7 @@ * gtk2_api.cpp: Various gtk2-specific functions ***************************************************************************** * Copyright (C) 2003 VideoLAN - * $Id: gtk2_api.cpp,v 1.7 2003/04/15 20:33:58 karibu Exp $ + * $Id: gtk2_api.cpp,v 1.8 2003/04/15 20:54:58 karibu Exp $ * * Authors: Cyril Deguet * @@ -121,11 +121,7 @@ void OSAPI_GetScreenSize( int &w, int &h ) //--------------------------------------------------------------------------- void OSAPI_GetMousePos( int &x, int &y ) { -/* LPPOINT MousePos = new POINT; - GetCursorPos( MousePos ); - x = MousePos->x; - y = MousePos->y; - delete MousePos;*/ + gdk_window_get_pointer( gdk_get_default_root_window(), &x, &y, NULL ); } //--------------------------------------------------------------------------- string OSAPI_GetWindowTitle( Window *win ) diff --git a/modules/gui/skins/gtk2/gtk2_event.cpp b/modules/gui/skins/gtk2/gtk2_event.cpp index 031bf3d3c2..91fe2d597d 100644 --- a/modules/gui/skins/gtk2/gtk2_event.cpp +++ b/modules/gui/skins/gtk2/gtk2_event.cpp @@ -2,7 +2,7 @@ * gtk2_event.cpp: GTK2 implementation of the Event class ***************************************************************************** * Copyright (C) 2003 VideoLAN - * $Id: gtk2_event.cpp,v 1.6 2003/04/15 20:33:58 karibu Exp $ + * $Id: gtk2_event.cpp,v 1.7 2003/04/15 20:54:58 karibu Exp $ * * Authors: Cyril Deguet * @@ -80,12 +80,14 @@ bool GTK2Event::SendEvent() { OSAPI_PostMessage( *win, Message, Param1, Param2 ); PostSynchroMessage(); + return true; } } + OSAPI_PostMessage( NULL, Message, Param1, Param2 ); + return true; } - OSAPI_PostMessage( NULL, Message, Param1, Param2 ); - return true; + return false; } //--------------------------------------------------------------------------- bool GTK2Event::IsEqual( Event *evt )