]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/calctrl.cpp
Change wxNotebook selection before sending page changed event in wxMSW.
[wxWidgets.git] / src / gtk / calctrl.cpp
index 2da9293d0bb3f35f1272bcf9e0f50dac88e79557..24b1d73347446f6ba1d5c6267350a6d83519d691 100644 (file)
@@ -142,17 +142,21 @@ bool wxGtkCalendarCtrl::SetDate(const wxDateTime& date)
 {
     g_signal_handlers_block_by_func(m_widget,
         (gpointer) gtk_day_selected_callback, this);
-        
+    g_signal_handlers_block_by_func(m_widget,
+        (gpointer) gtk_month_changed_callback, this);
+
     m_selectedDate = date;
     int year = date.GetYear();
     int month = date.GetMonth();
     int day = date.GetDay();
     gtk_calendar_select_month(GTK_CALENDAR(m_widget), month, year);
     gtk_calendar_select_day(GTK_CALENDAR(m_widget), day);
-    
+
+    g_signal_handlers_unblock_by_func( m_widget,
+        (gpointer) gtk_month_changed_callback, this);
     g_signal_handlers_unblock_by_func( m_widget,
         (gpointer) gtk_day_selected_callback, this);
-    
+
     return true;
 }
 
@@ -171,7 +175,4 @@ void wxGtkCalendarCtrl::Mark(size_t day, bool mark)
         gtk_calendar_unmark_day(GTK_CALENDAR(m_widget), day);
 }
 
-IMPLEMENT_DYNAMIC_CLASS(wxGtkCalendarCtrl, wxControl)
-
-
 #endif // wxUSE_CALENDARCTRL