REBAR: fix insertion of bands and non-client calculation in pager
control
Mike McCormack
mike at codeweavers.com
Fri Mar 12 00:27:07 CST 2004
ChangeLog:
<ulrichc at codeweavers.com>
* fix rebar band insertion and non-client calculation in pager control
-------------- next part --------------
Index: dlls/comctl32/rebar.c
===================================================================
RCS file: /home/wine/wine/dlls/comctl32/rebar.c,v
retrieving revision 1.85
diff -u -r1.85 rebar.c
--- dlls/comctl32/rebar.c 27 Feb 2004 04:32:54 -0000 1.85
+++ dlls/comctl32/rebar.c 12 Mar 2004 05:40:39 -0000
@@ -1674,7 +1674,7 @@
#if PROBLEM2
(x < adjcx) : (y < adjcy)
#else
- (adjcx - x > 4) : (adjcy - y > 4)
+ (adjcx - x > 5) : (adjcy - y > 4)
#endif
) &&
(infoPtr->uNumBands > 1)) {
@@ -3204,9 +3204,9 @@
}
/* post copy */
- if (uIndex < infoPtr->uNumBands - 1) {
+ if (uIndex <= infoPtr->uNumBands - 1) {
memcpy (&infoPtr->bands[uIndex+1], &oldBands[uIndex],
- (infoPtr->uNumBands - uIndex - 1) * sizeof(REBAR_BAND));
+ (infoPtr->uNumBands - uIndex) * sizeof(REBAR_BAND));
}
Free (oldBands);
@@ -3238,7 +3238,7 @@
REBAR_ValidateBand (infoPtr, lpBand);
/* On insert of second band, revalidate band 1 to possible add gripper */
if (infoPtr->uNumBands == 2)
- REBAR_ValidateBand (infoPtr, &infoPtr->bands[0]);
+ REBAR_ValidateBand (infoPtr, &infoPtr->bands[uIndex ? 0 : 1]);
REBAR_DumpBand (infoPtr);
More information about the wine-patches
mailing list