The position (mouse pos) returned by wxKeyEvent sometimes
was wrong, as it reported the position relative to the TLW (this is what a bug report claims, in any case). git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@32428 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -1000,6 +1000,8 @@ static void wxFillOtherKeyEventFields(wxKeyEvent& event,
|
|||||||
#if wxUSE_UNICODE
|
#if wxUSE_UNICODE
|
||||||
event.m_uniChar = gdk_keyval_to_unicode(gdk_event->keyval);
|
event.m_uniChar = gdk_keyval_to_unicode(gdk_event->keyval);
|
||||||
#endif
|
#endif
|
||||||
|
wxGetMousePosition( &x, &y );
|
||||||
|
win->ScreenToClient( &x, &y );
|
||||||
event.m_x = x;
|
event.m_x = x;
|
||||||
event.m_y = y;
|
event.m_y = y;
|
||||||
event.SetEventObject( win );
|
event.SetEventObject( win );
|
||||||
|
@@ -1000,6 +1000,8 @@ static void wxFillOtherKeyEventFields(wxKeyEvent& event,
|
|||||||
#if wxUSE_UNICODE
|
#if wxUSE_UNICODE
|
||||||
event.m_uniChar = gdk_keyval_to_unicode(gdk_event->keyval);
|
event.m_uniChar = gdk_keyval_to_unicode(gdk_event->keyval);
|
||||||
#endif
|
#endif
|
||||||
|
wxGetMousePosition( &x, &y );
|
||||||
|
win->ScreenToClient( &x, &y );
|
||||||
event.m_x = x;
|
event.m_x = x;
|
||||||
event.m_y = y;
|
event.m_y = y;
|
||||||
event.SetEventObject( win );
|
event.SetEventObject( win );
|
||||||
|
Reference in New Issue
Block a user