void DatePickerWidgetsPage::OnButtonSet(wxCommandEvent& WXUNUSED(event))
{
- long day = 0, month = 0, year = 0;
+ long day, month, year;
if ( m_day->GetValue().ToLong(&day) &&
m_month->GetValue().ToLong(&month) &&
m_year->GetValue().ToLong(&year) )
{
- const wxDateTime someDay(wxDateTime::wxDateTime_t(day),
- wxDateTime::Month(month),
- year);
- if(someDay.IsValid())
+ const wxDateTime someDay(day, wxDateTime::Month(month), year);
+ if ( someDay.IsValid() )
{
m_datePicker->SetValue(someDay);
}