From 0bb4ad85f3655a70319c488b6fbc09b850f63abe Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sun, 28 May 2006 15:20:32 +0000 Subject: [PATCH] fix crashes in the calctl sample under OS/2 (patch 1495898) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@39378 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/generic/calctrl.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/generic/calctrl.cpp b/src/generic/calctrl.cpp index 3af0091d42..cb0b01b5f8 100644 --- a/src/generic/calctrl.cpp +++ b/src/generic/calctrl.cpp @@ -788,7 +788,7 @@ void wxCalendarCtrl::DoMoveWindow(int x, int y, int width, int height) { int yDiff; - if ( !HasFlag(wxCAL_SEQUENTIAL_MONTH_SELECTION) ) + if ( !HasFlag(wxCAL_SEQUENTIAL_MONTH_SELECTION) && m_staticMonth ) { wxSize sizeCombo = m_comboMonth->GetSize(); wxSize sizeStatic = m_staticMonth->GetSize(); @@ -816,7 +816,7 @@ void wxCalendarCtrl::DoGetPosition(int *x, int *y) const { wxControl::DoGetPosition(x, y); - if ( !(GetWindowStyle() & wxCAL_SEQUENTIAL_MONTH_SELECTION) ) + if ( !HasFlag(wxCAL_SEQUENTIAL_MONTH_SELECTION) && GetMonthControl() ) { // our real top corner is not in this position if ( y ) -- 2.45.2