}
wxWizardPage::wxWizardPage(wxWizard *parent,
- const wxBitmap& bitmap,
- const wxChar *resource)
+ const wxBitmap& bitmap)
{
- Create(parent, bitmap, resource);
+ Create(parent, bitmap);
}
bool wxWizardPage::Create(wxWizard *parent,
- const wxBitmap& bitmap,
- const wxChar *resource)
+ const wxBitmap& bitmap)
{
if ( !wxPanel::Create(parent, wxID_ANY) )
return false;
- if ( resource != NULL )
- {
-#if wxUSE_WX_RESOURCES
-#if 0
- if ( !LoadFromResource(this, resource) )
- {
- wxFAIL_MSG(wxT("wxWizardPage LoadFromResource failed!!!!"));
- }
-#endif
-#endif // wxUSE_RESOURCES
- }
-
m_bitmap = bitmap;
// initially the page is hidden, it's shown only when it becomes current
return result;
}
+wxWizard::~wxWizard()
+{
+ // normally we don't have to delete this sizer as it's deleted by the
+ // associated window but if we never used it or didn't set it as the window
+ // sizer yet, do delete it manually
+ if ( !m_usingSizer || !m_started )
+ delete m_sizerPage;
+}
+
void wxWizard::AddBitmapRow(wxBoxSizer *mainColumn)
{
m_sizerBmpAndPage = new wxBoxSizer(wxHORIZONTAL);
}
}
+void wxWizard::SetBitmap(const wxBitmap& bitmap)
+{
+ m_bitmap = bitmap;
+ if (m_statbmp)
+ m_statbmp->SetBitmap(m_bitmap);
+}
+
// ----------------------------------------------------------------------------
// wxWizardEvent
// ----------------------------------------------------------------------------