// Setup the month selection control.
wxDateTime dtNow = wxDateTime::Now();
-
+
+#if defined(WIN32)
+ moo = new frmCalendarSelectMonth(this);
+#else
moo = new XCCalendarMonthSelect(this);
+#endif
month = ((int)dtNow.GetMonth() + 1);
year = dtNow.GetYear();
moo->UpdateDate(month, year);
// Bring up a popup control to select the month and year.
+ // TODO: Do something different for Win32.
+
moo->SetPosition(wxPoint(dateButton->GetScreenRect().GetLeft(), dateButton->GetScreenRect().GetBottom()));
moo->UpdateDate(month, year);
+#if defined(WIN32)
+ moo->ShowModal();
+#else
moo->Popup();
-
+#endif
+
}
void XCCalendarManipulator::ChangeGrid(wxCommandEvent &event){
#include <wx/mstream.h>
#include "events.h"
+#if defined(WIN32)
+#include "../forms/calendarselectmonth/frmCalendarSelectMonth.h"
+#else
#include "XCCalendarMonthSelect.h"
+#endif
#include "XCCalendarList.h"
#include "../bitmaps.h"
#include "../libraries/CalendarDataStorage/CalendarDataStorage.h"
wxButton *nextButton = nullptr;
wxButton *calendarsButton = nullptr;
wxButton *dateButton = nullptr;
+#if defined(WIN32)
+ frmCalendarSelectMonth *moo = nullptr;
+#else
XCCalendarMonthSelect *moo = nullptr;
+#endif
XCCalendarList *calendarList = nullptr;
CalendarDataStorage *dataStorage = nullptr;
int month = 0;