wxSize wxDatePickerCtrlGeneric::DoGetBestSize() const
{
- int bh=m_btn->GetBestSize().y;
- int eh=m_txt->GetBestSize().y;
- return wxSize(DEFAULT_ITEM_WIDTH, bh > eh ? bh : eh);
+ if (m_btn && m_txt)
+ {
+ int bh=m_btn->GetBestSize().y;
+ int eh=m_txt->GetBestSize().y;
+ return wxSize(DEFAULT_ITEM_WIDTH, bh > eh ? bh : eh);
+ }
+ return wxSize(DEFAULT_ITEM_WIDTH,DEFAULT_ITEM_HEIGHT);
}
{
if (dt1)
*dt1 = m_cal->GetLowerDateLimit();
- if (dt1)
+ if (dt2)
*dt2 = m_cal->GetUpperDateLimit();
return true;
}