Further RTL fixes.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@41162 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robert Roebling
2006-09-11 14:20:24 +00:00
parent f1a9b1a3d9
commit 428f4657b6
4 changed files with 29 additions and 2 deletions

View File

@@ -1284,7 +1284,12 @@ template<typename T> void InitMouseEvent(wxWindowGTK *win,
event.m_y = (wxCoord)gdk_event->y - pt.y;
if ((win->m_wxwindow) && (win->GetLayoutDirection() == wxLayout_RightToLeft))
event.m_x = GTK_PIZZA(win->m_wxwindow)->m_width - event.m_x;
{
// origin in the upper right corner
int virtual_width = win->GetVirtualSize().x;
int window_width = gtk_pizza_get_rtl_offset( GTK_PIZZA(win->m_wxwindow) );
event.m_x = wxMax( virtual_width, window_width ) - event.m_x;
}
event.SetEventObject( win );
event.SetId( win->GetId() );