Comment 1 for bug 352009

Revision history for this message
Stani (stani) wrote :

The fix has been committed upstream and will be part of next release.

$ bzr diff
=== modified file 'phatch/pyWx/gui.py'
--- phatch/pyWx/gui.py 2009-02-17 01:26:42 +0000
+++ phatch/pyWx/gui.py 2009-03-30 23:52:32 +0000
@@ -405,15 +405,16 @@
         self._open(filename)

     def on_menu_edit_add(self, event):
- dlg = dialogs.ActionDialog(self,api.ACTIONS,-1,
- size=(self._width, min(400,self._max_height)),
- title="%(name)s "%ct.INFO+_("actions"), )
- if dlg.ShowModal() == wx.ID_OK:
+ if not hasattr(self, 'dlgActions'):
+ self.dlgActions = dialogs.ActionDialog(self,api.ACTIONS,-1,
+ size=(self._width, min(400,self._max_height)),
+ title="%(name)s "%ct.INFO+_("actions"), )
+ if self.dlgActions.ShowModal() == wx.ID_OK:
             self.set_dirty(True)
- label = dlg.GetStringSelection()
+ label = self.dlgActions.GetStringSelection()
             self.tree.append_form_by_label_to_selected(label)
             self.enable_actions(True)
- dlg.Destroy()
+ self.dlgActions.Hide()

$ bzr commit -m "remember last action dialog"
Committing to: /home/stani/sync/python/phatch/trunk/
modified phatch/pyWx/gui.py
Committed revision 555.