From: Stefan Csomor Date: Wed, 24 Apr 2002 16:54:28 +0000 (+0000) Subject: corrected eventobject setting for mouse events and capture X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/2e6857fac2a88987fff1c63c8885252f679ac6ce corrected eventobject setting for mouse events and capture git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15255 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/mac/carbon/toplevel.cpp b/src/mac/carbon/toplevel.cpp index 1c5d96ed76..8db3f7e902 100644 --- a/src/mac/carbon/toplevel.cpp +++ b/src/mac/carbon/toplevel.cpp @@ -429,6 +429,7 @@ void wxTopLevelWindowMac::MacFireMouseEvent( WXEVENTREF evr ) wxTheApp->s_captureWindow->ScreenToClient( &x , &y ) ; event.m_x = x ; event.m_y = y ; + event.SetEventObject( wxTheApp->s_captureWindow ) ; wxTheApp->s_captureWindow->GetEventHandler()->ProcessEvent( event ) ; if ( ev->what == mouseUp ) diff --git a/src/mac/carbon/window.cpp b/src/mac/carbon/window.cpp index fd36642550..9d9fdb5cc6 100644 --- a/src/mac/carbon/window.cpp +++ b/src/mac/carbon/window.cpp @@ -1417,6 +1417,7 @@ bool wxWindowMac::MacDispatchMouseEvent(wxMouseEvent& event) event.m_x = x ; event.m_y = y ; + event.SetEventObject( this ) ; if ( wxBusyCursorCount == 0 ) { diff --git a/src/mac/toplevel.cpp b/src/mac/toplevel.cpp index 1c5d96ed76..8db3f7e902 100644 --- a/src/mac/toplevel.cpp +++ b/src/mac/toplevel.cpp @@ -429,6 +429,7 @@ void wxTopLevelWindowMac::MacFireMouseEvent( WXEVENTREF evr ) wxTheApp->s_captureWindow->ScreenToClient( &x , &y ) ; event.m_x = x ; event.m_y = y ; + event.SetEventObject( wxTheApp->s_captureWindow ) ; wxTheApp->s_captureWindow->GetEventHandler()->ProcessEvent( event ) ; if ( ev->what == mouseUp ) diff --git a/src/mac/window.cpp b/src/mac/window.cpp index fd36642550..9d9fdb5cc6 100644 --- a/src/mac/window.cpp +++ b/src/mac/window.cpp @@ -1417,6 +1417,7 @@ bool wxWindowMac::MacDispatchMouseEvent(wxMouseEvent& event) event.m_x = x ; event.m_y = y ; + event.SetEventObject( this ) ; if ( wxBusyCursorCount == 0 ) {