X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/34b29ae796059f5a0f856dbfc6883ab30d897a39..46ae103b9f08fc4e447d16a6a92b03cf55ee3189:/wxPython/wx/tools/XRCed/xrced.py?ds=inline diff --git a/wxPython/wx/tools/XRCed/xrced.py b/wxPython/wx/tools/XRCed/xrced.py index 0a294014d9..a68597b7fd 100644 --- a/wxPython/wx/tools/XRCed/xrced.py +++ b/wxPython/wx/tools/XRCed/xrced.py @@ -314,6 +314,7 @@ class Frame(wxFrame): EVT_CLOSE(self, self.OnCloseWindow) EVT_KEY_DOWN(self, tools.OnKeyDown) EVT_KEY_UP(self, tools.OnKeyUp) + EVT_ICONIZE(self, self.OnIconize) def AppendRecent(self, menu): # add recently used files to the menu @@ -963,6 +964,17 @@ Homepage: http://xrced.sourceforge.net\ def OnCloseMiniFrame(self, evt): return + def OnIconize(self, evt): + conf.x, conf.y = self.GetPosition() + conf.width, conf.height = self.GetSize() + if conf.embedPanel: + conf.sashPos = self.splitter.GetSashPosition() + else: + conf.panelX, conf.panelY = self.miniFrame.GetPosition() + conf.panelWidth, conf.panelHeight = self.miniFrame.GetSize() + self.miniFrame.Iconize() + evt.Skip() + def OnCloseWindow(self, evt): if not self.AskSave(): return if g.testWin: g.testWin.Destroy()