X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/bb61a98381b44ba2f4aef4c3bfd4b19f66a1b923..b2261c5bb8eff491a42eddc817a4c1fd1d9db15f:/src/generic/calctrl.cpp diff --git a/src/generic/calctrl.cpp b/src/generic/calctrl.cpp index 176bc6e0f9..dd81cba7fe 100644 --- a/src/generic/calctrl.cpp +++ b/src/generic/calctrl.cpp @@ -680,8 +680,11 @@ size_t wxCalendarCtrl::GetWeek(const wxDateTime& date) const // the constants used for the layout #define VERT_MARGIN 5 // distance between combo and calendar +#ifdef __WXMAC__ +#define HORZ_MARGIN 5 // spin +#else #define HORZ_MARGIN 15 // spin - +#endif wxSize wxCalendarCtrl::DoGetBestSize() const { // calc the size of the calendar @@ -765,7 +768,7 @@ void wxCalendarCtrl::DoGetSize(int *width, int *height) const if ( !(GetWindowStyle() & wxCAL_SEQUENTIAL_MONTH_SELECTION) ) { // our real height is bigger - if ( height ) + if ( height && GetMonthControl()) { *height += GetMonthControl()->GetSize().y + VERT_MARGIN; }