~ubuntu-branches/ubuntu/wily/wxwidgets3.0/wily-proposed

« back to all changes in this revision

Viewing changes to samples/calendar/calendar.cpp

  • Committer: Package Import Robot
  • Author(s): Olly Betts
  • Date: 2014-06-18 12:42:22 UTC
  • mfrom: (1.1.1)
  • Revision ID: package-import@ubuntu.com-20140618124222-y7t2vpsije1cesxy
Tags: 3.0.1-1
* New upstream release
  + Incorporates most of the patches we were carrying - only one left is:
    wx-config-conditionalise-webview-in-std.patch
* Drop versioning of dependencies from run-time libraries to wx-common -
  this will make the transition to the next wx version harder, and also
  makes backporting to wheezy more work.
* Mark -dbg packages as "Multi-Arch: same".
* Correct short descriptions of the webview packages to not just be
  copies of the corresponding media package's short description.
* Wrap 81 character line in package description.

Show diffs side-by-side

added added

removed removed

Lines of Context:
121
121
    bool m_usingGeneric;
122
122
 
123
123
 
124
 
    DECLARE_EVENT_TABLE()
 
124
    wxDECLARE_EVENT_TABLE();
125
125
};
126
126
 
127
127
// Define a new frame type: this is going to be our main frame
181
181
    wxTextCtrl *m_logWindow;
182
182
 
183
183
    // any class wishing to process wxWidgets events must use this macro
184
 
    DECLARE_EVENT_TABLE()
 
184
    wxDECLARE_EVENT_TABLE();
185
185
};
186
186
 
187
187
#if wxUSE_DATEPICKCTRL
202
202
    wxStaticText *m_dateText;
203
203
 
204
204
 
205
 
    DECLARE_EVENT_TABLE()
 
205
    wxDECLARE_EVENT_TABLE();
206
206
};
207
207
 
208
208
#endif // wxUSE_DATEPICKCTRL
278
278
// the event tables connect the wxWidgets events with the functions (event
279
279
// handlers) which process them. It can be also done at run-time, but for the
280
280
// simple menu events like this the static method is much simpler.
281
 
BEGIN_EVENT_TABLE(MyFrame, wxFrame)
 
281
wxBEGIN_EVENT_TABLE(MyFrame, wxFrame)
282
282
    EVT_MENU(Calendar_File_About, MyFrame::OnAbout)
283
283
    EVT_MENU(Calendar_File_ClearLog, MyFrame::OnClearLog)
284
284
    EVT_MENU(Calendar_File_Quit,  MyFrame::OnQuit)
324
324
#endif
325
325
    EVT_UPDATE_UI(Calendar_Cal_Special, MyFrame::OnUpdateUIGenericOnly)
326
326
    EVT_UPDATE_UI(Calendar_Cal_SurroundWeeks, MyFrame::OnUpdateUIGenericOnly)
327
 
END_EVENT_TABLE()
 
327
wxEND_EVENT_TABLE()
328
328
 
329
 
BEGIN_EVENT_TABLE(MyPanel, wxPanel)
 
329
wxBEGIN_EVENT_TABLE(MyPanel, wxPanel)
330
330
    EVT_CALENDAR(Calendar_CalCtrl, MyPanel::OnCalendar)
331
331
    EVT_CALENDAR_PAGE_CHANGED(Calendar_CalCtrl, MyPanel::OnCalMonthChange)
332
332
    EVT_CALENDAR_SEL_CHANGED(Calendar_CalCtrl, MyPanel::OnCalendarChange)
333
333
    EVT_CALENDAR_WEEKDAY_CLICKED(Calendar_CalCtrl, MyPanel::OnCalendarWeekDayClick)
334
334
    EVT_CALENDAR_WEEK_CLICKED(Calendar_CalCtrl,  MyPanel::OnCalendarWeekClick)
335
 
END_EVENT_TABLE()
 
335
wxEND_EVENT_TABLE()
336
336
 
337
337
// Create a new application object: this macro will allow wxWidgets to create
338
338
// the application object during program execution (it's better than using a
892
892
 
893
893
#if wxUSE_DATEPICKCTRL
894
894
 
895
 
BEGIN_EVENT_TABLE(MyDateDialog, wxDialog)
 
895
wxBEGIN_EVENT_TABLE(MyDateDialog, wxDialog)
896
896
    EVT_DATE_CHANGED(wxID_ANY, MyDateDialog::OnDateChange)
897
 
END_EVENT_TABLE()
 
897
wxEND_EVENT_TABLE()
898
898
 
899
899
MyDateDialog::MyDateDialog(wxWindow *parent, const wxDateTime& dt, int dtpStyle)
900
900
        : wxDialog(parent, wxID_ANY, wxString(wxT("Calendar: Choose a date")))
950
950
 
951
951
#if wxUSE_TIMEPICKCTRL
952
952
 
953
 
BEGIN_EVENT_TABLE(MyTimeDialog, wxDialog)
 
953
wxBEGIN_EVENT_TABLE(MyTimeDialog, wxDialog)
954
954
    EVT_TIME_CHANGED(wxID_ANY, MyTimeDialog::OnTimeChange)
955
 
END_EVENT_TABLE()
 
955
wxEND_EVENT_TABLE()
956
956
 
957
957
MyTimeDialog::MyTimeDialog(wxWindow *parent)
958
958
        : wxDialog(parent, wxID_ANY, wxString(wxT("Calendar: Choose time")))