Alexandre Julliard : shell32: Properly handle negative coordinates for mouse events.

Alexandre Julliard julliard at wine.codeweavers.com
Wed Oct 25 13:29:07 CDT 2006


Module: wine
Branch: master
Commit: ff068c088b53a54915e9d59831b98ce80c4a5cfb
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=ff068c088b53a54915e9d59831b98ce80c4a5cfb

Author: Alexandre Julliard <julliard at winehq.org>
Date:   Wed Oct 25 17:42:11 2006 +0200

shell32: Properly handle negative coordinates for mouse events.

---

 dlls/shell32/control.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/shell32/control.c b/dlls/shell32/control.c
index f9f6db8..f38a920 100644
--- a/dlls/shell32/control.c
+++ b/dlls/shell32/control.c
@@ -163,7 +163,7 @@ #define XSTEP	128
 #define	YICON	32
 #define YSTEP	64
 
-static BOOL	Control_Localize(const CPanel* panel, unsigned cx, unsigned cy,
+static BOOL	Control_Localize(const CPanel* panel, int cx, int cy,
 				 CPlApplet** papplet, unsigned* psp)
 {
     unsigned	i, x = (XSTEP-XICON)/2, y = 0;
@@ -228,7 +228,7 @@ static LRESULT Control_WndProc_LButton(C
     unsigned	i;
     CPlApplet*	applet;
 
-    if (Control_Localize(panel, LOWORD(lParam), HIWORD(lParam), &applet, &i)) {
+    if (Control_Localize(panel, (short)LOWORD(lParam), (short)HIWORD(lParam), &applet, &i)) {
        if (up) {
 	   if (panel->clkApplet == applet && panel->clkSP == i) {
 	       applet->proc(applet->hWnd, CPL_DBLCLK, i, applet->info[i].lData);




More information about the wine-cvs mailing list