wxEXPAND // No border, (mostly useless) horizontal stretching
);
+#if wxUSE_STATBMP
if ( m_bitmap.Ok() )
{
m_statbmp = new wxStaticBitmap(this, -1, m_bitmap);
wxEXPAND // No border, (mostly useless) vertical stretching
);
}
+#endif
// Added to m_sizerBmpAndPage in FinishLayout
m_sizerPage = new wxWizardSizer(this);
void wxWizard::AddBackNextPair(wxBoxSizer *buttonRow)
{
- wxASSERT_MSG(m_btnNext!=0 && m_btnPrev!=0, "You must create the buttons first before calling wxWizard::AddBackNextPair");
+ wxASSERT_MSG( m_btnNext && m_btnPrev,
+ _T("You must create the buttons before calling ")
+ _T("wxWizard::AddBackNextPair") );
+
// margin between Back and Next buttons
#ifdef __WXMAC__
static const int BACKNEXT_MARGIN = 10;
{
// terminate successfully
EndModal(wxID_OK);
- if ( !IsModal() )
- {
- wxWizardEvent event(wxEVT_WIZARD_FINISHED, GetId(),FALSE, 0);
- (void)GetEventHandler()->ProcessEvent(event);
- }
+
+ // and notify the user code (this is especially useful for modeless
+ // wizards)
+ wxWizardEvent event(wxEVT_WIZARD_FINISHED, GetId(), FALSE, 0);
+ (void)GetEventHandler()->ProcessEvent(event);
+
return TRUE;
}
bmpIsDefault = FALSE;
}
+#if wxUSE_STATBMP
// change the bitmap if:
// 1) a default bitmap was selected in constructor
// 2) this page was constructed with a bitmap
bmp = m_page->GetBitmap();
m_statbmp->SetBitmap(bmp);
}
+#endif
// and update the buttons state
m_btnPrev->Enable(HasPrevPage(m_page));
else
m_btnNext->SetLabel(_("&Next >"));
}
+ m_btnNext->SetDefault();
// nothing to do: the label was already correct
// send the change event to the new page now
if ( !(GetExtraStyle() & wxWS_EX_BLOCK_EVENTS) )
{
// the event will be propagated anyhow
+ event.Skip();
return;
}
// our public interface
// ----------------------------------------------------------------------------
-#ifdef WXWIN_COMPATIBILITY_2_2
+#if WXWIN_COMPATIBILITY_2_2
/* static */
wxWizard *wxWizardBase::Create(wxWindow *parent,