Joel Holdsworth : comctl32/rebar: Moved drag notify code into REBAR_MouseMove.
Alexandre Julliard
julliard at winehq.org
Mon Jan 10 10:55:21 CST 2011
Module: wine
Branch: master
Commit: 53284d2a18e49d9fea9e6db47378918498155e30
URL: http://source.winehq.org/git/wine.git/?a=commit;h=53284d2a18e49d9fea9e6db47378918498155e30
Author: Joel Holdsworth <joel at airwebreathe.org.uk>
Date: Sun Jan 9 09:40:15 2011 +0000
comctl32/rebar: Moved drag notify code into REBAR_MouseMove.
---
dlls/comctl32/rebar.c | 28 ++++++++++++++--------------
1 files changed, 14 insertions(+), 14 deletions(-)
diff --git a/dlls/comctl32/rebar.c b/dlls/comctl32/rebar.c
index 5ab55d4..6549638 100644
--- a/dlls/comctl32/rebar.c
+++ b/dlls/comctl32/rebar.c
@@ -2044,20 +2044,6 @@ REBAR_HandleLRDrag (REBAR_INFO *infoPtr, const POINT *ptsmove)
INT movement, xBand, cxLeft = 0;
BOOL shrunkBands = FALSE;
- /* on first significant mouse movement, issue notify */
- if (!(infoPtr->fStatus & BEGIN_DRAG_ISSUED)) {
- if (REBAR_Notify_NMREBAR (infoPtr, -1, RBN_BEGINDRAG)) {
- /* Notify returned TRUE - abort drag */
- infoPtr->dragStart.x = 0;
- infoPtr->dragStart.y = 0;
- infoPtr->dragNow = infoPtr->dragStart;
- infoPtr->iGrabbedBand = -1;
- ReleaseCapture ();
- return ;
- }
- infoPtr->fStatus |= BEGIN_DRAG_ISSUED;
- }
-
iHitBand = infoPtr->iGrabbedBand;
iRowBegin = get_row_begin_for_band(infoPtr, iHitBand);
iRowEnd = get_row_end_for_band(infoPtr, iHitBand);
@@ -3095,6 +3081,20 @@ REBAR_MouseMove (REBAR_INFO *infoPtr, LPARAM lParam)
if ((abs(ptMove.x - infoPtr->dragNow.x) <= mindragx) &&
(abs(ptMove.y - infoPtr->dragNow.y) <= mindragy)) return 0;
+ /* on first significant mouse movement, issue notify */
+ if (!(infoPtr->fStatus & BEGIN_DRAG_ISSUED)) {
+ if (REBAR_Notify_NMREBAR (infoPtr, -1, RBN_BEGINDRAG)) {
+ /* Notify returned TRUE - abort drag */
+ infoPtr->dragStart.x = 0;
+ infoPtr->dragStart.y = 0;
+ infoPtr->dragNow = infoPtr->dragStart;
+ infoPtr->iGrabbedBand = -1;
+ ReleaseCapture ();
+ return 0;
+ }
+ infoPtr->fStatus |= BEGIN_DRAG_ISSUED;
+ }
+
/* Test for valid drag case - must not be first band in row */
if ((yPtMove < band->rcBand.top) ||
(yPtMove > band->rcBand.bottom)) {
More information about the wine-cvs
mailing list