def show(self): self.dialog = ParaDialog(WindowsManager.get(), self.title) self.dialog.init_view(self.view, self.para, 'preview' in self.note, modal=self.modal) self.dialog.set_handle(lambda x: self.preview(self.para)) if self.modal: return self.dialog.ShowModal() self.dialog.on_ok = lambda: self.ok(self.ips) self.dialog.on_cancel = lambda: self.cancel(self.ips) self.dialog.Show()
def show(self): if self.view==None:return wx.ID_OK self.dialog = ParaDialog(IPy.get_window(), self.title) self.dialog.init_view(self.view, self.para, modal=True) return self.dialog.ShowModal()
def get_para(title, view, para): pd = ParaDialog(curapp, title) pd.init_view(view, para) rst = pd.ShowModal() pd.Destroy() return rst