Added chainable wxWizardPageSimple::Chain() overload.
Add the simplest and most fool proof of chaining the pages in static wizards: just chain several calls to the new, non-static, wxWizardPageSimple::Chain() overload. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73806 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -414,8 +414,10 @@ MyWizard::MyWizard(wxFrame *frame, bool useSizer)
|
||||
wxValidationPage *page4 = new wxValidationPage(this);
|
||||
|
||||
// set the page order using a convenience function - could also use
|
||||
// SetNext/Prev directly as below
|
||||
wxWizardPageSimple::Chain(page3, page4);
|
||||
// SetNext/Prev directly as below, but Chain() is shorter, avoids the risk
|
||||
// of an error and can itself be chained, e.g. you could write
|
||||
// page3.Chain(page4).Chain(page5) and so on.
|
||||
page3->Chain(page4);
|
||||
|
||||
// this page is not a wxWizardPageSimple, so we use SetNext/Prev to insert
|
||||
// it into the chain of pages
|
||||
|
Reference in New Issue
Block a user