IMPLEMENT_DYNAMIC_CLASS(wxChoicebook, wxBookCtrlBase)
-wxDEFINE_EVENT( wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGING, wxBookCtrlEvent )
-wxDEFINE_EVENT( wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGED, wxBookCtrlEvent )
+wxDEFINE_EVENT( wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGING, wxBookCtrlEvent );
+wxDEFINE_EVENT( wxEVT_COMMAND_CHOICEBOOK_PAGE_CHANGED, wxBookCtrlEvent );
BEGIN_EVENT_TABLE(wxChoicebook, wxBookCtrlBase)
EVT_CHOICE(wxID_ANY, wxChoicebook::OnChoiceSelected)
int wxChoicebook::GetPageImage(size_t WXUNUSED(n)) const
{
- wxFAIL_MSG( _T("wxChoicebook::GetPageImage() not implemented") );
+ wxFAIL_MSG( wxT("wxChoicebook::GetPageImage() not implemented") );
return wxNOT_FOUND;
}
bool wxChoicebook::SetPageImage(size_t WXUNUSED(n), int WXUNUSED(imageId))
{
- wxFAIL_MSG( _T("wxChoicebook::SetPageImage() not implemented") );
+ wxFAIL_MSG( wxT("wxChoicebook::SetPageImage() not implemented") );
return false;
}
void wxChoicebook::DoSetWindowVariant(wxWindowVariant variant)
{
- wxCHECK_RET( m_bookctrl, "can't be called before control creation" );
-
- m_bookctrl->SetWindowVariant(variant);
+ wxBookCtrlBase::DoSetWindowVariant(variant);
+ if (m_bookctrl)
+ m_bookctrl->SetWindowVariant(variant);
}
void wxChoicebook::SetImageList(wxImageList *imageList)