how could i stick my wxwizard code into a seperate class?

Code:
from wxPython.wx import *
from wxPython.wizard import *

ID_ABOUT = 101
ID_EXIT  = 102
ID_WIZARD = 103

def makePageTitle(wizPg, title):
    sizer = wxBoxSizer(wxVERTICAL)
    wizPg.SetSizer(sizer)
    title = wxStaticText(wizPg, -1, title)
    title.SetFont(wxFont(18, wxSWISS, wxNORMAL, wxBOLD))
    sizer.AddWindow(title, 0, wxALIGN_CENTRE|wxALL, 5)
    sizer.AddWindow(wxStaticLine(wizPg, -1), 0, wxEXPAND|wxALL, 5)
    return sizer

class TitledPage(wxWizardPageSimple):
    def __init__(self, parent, title):
        wxWizardPageSimple.__init__(self, parent)
        self.sizer = makePageTitle(self, title)

class MyFrame(wxFrame):
	ID_wiz = wxNewId()

	def __init__(self, parent, ID, title):
		wxFrame.__init__(self, parent, ID, title, wxDefaultPosition, wxSize(200, 150))
		self.CreateStatusBar()
		self.SetStatusText('Status Bar')
                menu = wxMenu()
                menu.Append(ID_ABOUT, "&About", "More information about this program")
                menu.AppendSeparator()
                menu.Append(ID_EXIT, "E&xit", "Terminate the program")
		menu.AppendSeparator()
		menu.Append(ID_WIZARD, "&Wizard", "Run the Wizard")
         
                menuBar = wxMenuBar()
                menuBar.Append(menu, "&File");
         
                self.SetMenuBar(menuBar)
                EVT_MENU(self, ID_ABOUT, self.OnAbout)
		EVT_MENU(self, ID_WIZARD, self.RunWizard)
                EVT_MENU(self, ID_EXIT,  self.TimeToQuit)

	def RunWizard(self, event):
		# Create the wizard and the pages
       		wizard = wxWizard(self, self.ID_wiz, "Wizard")
        	page1 = TitledPage(wizard, "Page 1")
        	page2 = TitledPage(wizard, "Page 2")
        	page3 = TitledPage(wizard, "Page 3")
        	page4 = TitledPage(wizard, "Page 4")
       		self.page1 = page1

        	page1.sizer.Add(wxStaticText(page1, -1, """
			This wizard is totally useless, but is meant to show how to
			chain simple wizard pages together in a non-dynamic manner.
			IOW, the order of the pages never changes, and so the
			wxWizardPageSimple class can easily be used for the pages."""))
       		wizard.FitToPage(page1)
        	page4.sizer.Add(wxStaticText(page4, -1, "\nThis is the last page."))

        	# Use the convenience Chain function to connect the pages
        	wxWizardPageSimple_Chain(page1, page2)
        	wxWizardPageSimple_Chain(page2, page3)
        	wxWizardPageSimple_Chain(page3, page4)

        	wizard.RunWizard(page1)
		#if wizard.RunWizard(page1):
            	#	wxMessageBox("Wizard completed successfully", "That's all folks!")
        	#else:
            	#	wxMessageBox("Wizard was cancelled", "That's all folks!")

                
        def OnAbout(self, event):
                dlg = wxMessageDialog(self, "This sample program shows off\n"
                                      	    "frames, menus, statusbars, and this\n"
                                       	    "message dialog.",
                                      	    "About Me", wxOK | wxICON_INFORMATION)
                dlg.ShowModal()
                dlg.Destroy()
         
        def TimeToQuit(self, event):
                self.Close(true)

class MyApp(wxApp):
	def OnInit(self):
		frame = MyFrame(NULL, -1, 'Hfi')
		frame.Show(true)
		self.SetTopWindow(frame)
		return true

app = MyApp(0)
app.MainLoop()
Thanks.