From 8fc7ab895b5b6def7f1d581d987f92fc86139eec Mon Sep 17 00:00:00 2001 From: HomeWorld Date: Sat, 9 Oct 2010 20:09:34 +0300 Subject: [PATCH] Changed dmgpattern editor to modal dialog --- gui/builtinContextMenus/damagePattern.py | 2 ++ gui/patternEditor.py | 5 +++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/gui/builtinContextMenus/damagePattern.py b/gui/builtinContextMenus/damagePattern.py index 3c6135355..3bb0ad4fe 100755 --- a/gui/builtinContextMenus/damagePattern.py +++ b/gui/builtinContextMenus/damagePattern.py @@ -17,4 +17,6 @@ class DamagePattern(ContextMenu): def activate(self, context, selection, i): dlg=DmgPatternEditorDlg(self.mainFrame) + dlg.ShowModal() + dlg.Destroy() DamagePattern.register() diff --git a/gui/patternEditor.py b/gui/patternEditor.py index 812c6d868..cd89f4ae5 100644 --- a/gui/patternEditor.py +++ b/gui/patternEditor.py @@ -151,8 +151,9 @@ class DmgPatternEditorDlg ( wx.Dialog ): self.Layout() bsize = self.GetBestSize() self.SetSize((-1,bsize.height)) - self.Show() - +# +# edit controls are editEM editTHERM editKIN editEXP +# self.new.Bind(wx.EVT_BUTTON, self.newPattern) self.rename.Bind(wx.EVT_BUTTON, self.renamePattern) self.delete.Bind(wx.EVT_BUTTON, self.deletePattern)