Module: wine Branch: master Commit: 75fbef2ded1f47d5034a6ffc3d0ece99901304b3 URL: http://source.winehq.org/git/wine.git/?a=commit;h=75fbef2ded1f47d5034a6ffc3d...
Author: Andrew Eikum aeikum@codeweavers.com Date: Thu Aug 29 14:57:48 2013 -0500
comctl32: Return the number of visible months for MCM_GETMONTHDELTA.
---
dlls/comctl32/monthcal.c | 5 ++--- dlls/comctl32/tests/monthcal.c | 3 +++ 2 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/dlls/comctl32/monthcal.c b/dlls/comctl32/monthcal.c index ef2ad68..84a01da 100644 --- a/dlls/comctl32/monthcal.c +++ b/dlls/comctl32/monthcal.c @@ -123,7 +123,6 @@ typedef struct int width_increment; INT delta; /* scroll rate; # of months that the */ /* control moves when user clicks a scroll button */ - int visible; /* # of months visible */ int firstDay; /* Start month calendar with firstDay's day, stored in SYSTEMTIME format */ BOOL firstDaySet; /* first week day differs from locale defined */ @@ -1302,8 +1301,8 @@ MONTHCAL_GetMonthDelta(const MONTHCAL_INFO *infoPtr)
if(infoPtr->delta) return infoPtr->delta; - else - return infoPtr->visible; + + return MONTHCAL_GetMonthRange(infoPtr, GMR_VISIBLE, NULL); }
diff --git a/dlls/comctl32/tests/monthcal.c b/dlls/comctl32/tests/monthcal.c index 5440f49..1cadf44 100644 --- a/dlls/comctl32/tests/monthcal.c +++ b/dlls/comctl32/tests/monthcal.c @@ -1325,6 +1325,9 @@ static void test_scroll(void)
hwnd = create_monthcal_control(0);
+ res = SendMessage(hwnd, MCM_GETMONTHDELTA, 0, 0); + expect(2, res); + flush_sequences(sequences, NUM_MSG_SEQUENCES);
/* Setter and Getters for scroll rate */