Commit d2f4893c authored by Piotr Caban's avatar Piotr Caban Committed by Alexandre Julliard

comctl32: Don't update rebar layout if it doesn't change in REBAR_HandleUDDrag.

parent a9c6113c
...@@ -2136,6 +2136,8 @@ REBAR_HandleUDDrag (REBAR_INFO *infoPtr, const POINT *ptsmove) ...@@ -2136,6 +2136,8 @@ REBAR_HandleUDDrag (REBAR_INFO *infoPtr, const POINT *ptsmove)
if(yOff < 0) if(yOff < 0)
{ {
/* Place the band above the current top row */ /* Place the band above the current top row */
if(iHitBand==0 && (infoPtr->uNumBands==1 || REBAR_GetBand(infoPtr, 1)->fStyle&RBBS_BREAK))
return;
DPA_DeletePtr(infoPtr->bands, iHitBand); DPA_DeletePtr(infoPtr->bands, iHitBand);
hitBand->fStyle &= RBBS_BREAK; hitBand->fStyle &= RBBS_BREAK;
REBAR_GetBand(infoPtr, 0)->fStyle |= RBBS_BREAK; REBAR_GetBand(infoPtr, 0)->fStyle |= RBBS_BREAK;
...@@ -2145,6 +2147,8 @@ REBAR_HandleUDDrag (REBAR_INFO *infoPtr, const POINT *ptsmove) ...@@ -2145,6 +2147,8 @@ REBAR_HandleUDDrag (REBAR_INFO *infoPtr, const POINT *ptsmove)
else if(yOff > REBAR_GetBand(infoPtr, infoPtr->uNumBands - 1)->rcBand.bottom) else if(yOff > REBAR_GetBand(infoPtr, infoPtr->uNumBands - 1)->rcBand.bottom)
{ {
/* Place the band below the current bottom row */ /* Place the band below the current bottom row */
if(iHitBand == infoPtr->uNumBands-1 && hitBand->fStyle&RBBS_BREAK)
return;
DPA_DeletePtr(infoPtr->bands, iHitBand); DPA_DeletePtr(infoPtr->bands, iHitBand);
hitBand->fStyle |= RBBS_BREAK; hitBand->fStyle |= RBBS_BREAK;
infoPtr->iGrabbedBand = DPA_InsertPtr( infoPtr->iGrabbedBand = DPA_InsertPtr(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment