Module: wine Branch: master Commit: d39d2da06534abca9be3464675858a24137603ca URL: http://source.winehq.org/git/wine.git/?a=commit;h=d39d2da06534abca9be3464675...
Author: Alexandre Julliard julliard@winehq.org Date: Thu Oct 7 14:26:21 2010 +0200
winex11: Mirror the client rectangle if necessary for update_window_zorder.
---
dlls/winex11.drv/event.c | 3 +++ dlls/winex11.drv/mouse.c | 13 +++++++++---- 2 files changed, 12 insertions(+), 4 deletions(-)
diff --git a/dlls/winex11.drv/event.c b/dlls/winex11.drv/event.c index a1e0d7f..9fbb002 100644 --- a/dlls/winex11.drv/event.c +++ b/dlls/winex11.drv/event.c @@ -744,6 +744,9 @@ static void X11DRV_Expose( HWND hwnd, XEvent *xev )
if (event->window != root_window) { + if (GetWindowLongW( data->hwnd, GWL_EXSTYLE ) & WS_EX_LAYOUTRTL) + mirror_rect( &data->client_rect, &rect ); + SERVER_START_REQ( update_window_zorder ) { req->window = wine_server_user_handle( hwnd ); diff --git a/dlls/winex11.drv/mouse.c b/dlls/winex11.drv/mouse.c index b725823..4103a80 100644 --- a/dlls/winex11.drv/mouse.c +++ b/dlls/winex11.drv/mouse.c @@ -238,13 +238,18 @@ static void update_mouse_state( HWND hwnd, Window window, int x, int y, unsigned /* ignore event if a button is pressed, since the mouse is then grabbed too */ !(state & (Button1Mask|Button2Mask|Button3Mask|Button4Mask|Button5Mask|Button6Mask|Button7Mask))) { + RECT rect; + SetRect( &rect, x, y, x + 1, y + 1 ); + if (GetWindowLongW( data->hwnd, GWL_EXSTYLE ) & WS_EX_LAYOUTRTL) + mirror_rect( &data->client_rect, &rect ); + SERVER_START_REQ( update_window_zorder ) { req->window = wine_server_user_handle( hwnd ); - req->rect.left = x; - req->rect.top = y; - req->rect.right = x + 1; - req->rect.bottom = y + 1; + req->rect.left = rect.left; + req->rect.top = rect.top; + req->rect.right = rect.right; + req->rect.bottom = rect.bottom; wine_server_call( req ); } SERVER_END_REQ;