def Configure(self, sourceCode=""): panel = eg.ConfigPanel(resizable=True) editCtrl = eg.PythonEditorCtrl(panel, value=sourceCode) panel.sizer.Add(editCtrl, 1, wx.EXPAND) panel.dialog.FinishSetup() panel.dialog.SetPosition(Config.position) panel.dialog.SetSize(Config.size) eg.Utils.EnsureVisible(panel.dialog) while panel.Affirmed(): panel.SetResult(editCtrl.GetValue()) if not panel.dialog.IsMaximized(): Config.size = panel.dialog.GetSizeTuple() Config.position = panel.dialog.GetPositionTuple()
def Configure(self, sourceCode=""): panel = eg.ConfigPanel(resizable=True) editCtrl = eg.PythonEditorCtrl(panel, value=sourceCode) panel.sizer.Add(editCtrl, 1, wx.EXPAND) while panel.Affirmed(): panel.SetResult(editCtrl.GetValue(), )