Implement wxCalendarCtrl::SetDateRange() in the native GTK version.

While GTK+ doesn't support imposing ranges for dates selection natively, we
can do it ourselves by preventing the user from selecting any date outside of
the currently valid range.

This allows to use ranges under all platforms and not only in wxCalendarCtrl
itself but in wxDatePickerCtrl as well.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67987 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2011-06-19 22:46:36 +00:00
parent 459c6f2a8a
commit 106f0d98f8
5 changed files with 99 additions and 20 deletions

View File

@@ -280,7 +280,6 @@ BEGIN_EVENT_TABLE(MyFrame, wxFrame)
#ifdef __WXGTK20__
EVT_UPDATE_UI(Calendar_Cal_Monday, MyFrame::OnUpdateUIGenericOnly)
EVT_UPDATE_UI(Calendar_Cal_Holidays, MyFrame::OnUpdateUIGenericOnly)
EVT_UPDATE_UI(Calendar_Cal_LimitDates, MyFrame::OnUpdateUIGenericOnly)
#endif
EVT_UPDATE_UI(Calendar_Cal_Special, MyFrame::OnUpdateUIGenericOnly)
EVT_UPDATE_UI(Calendar_Cal_SurroundWeeks, MyFrame::OnUpdateUIGenericOnly)