-------

Fix for dealing with empty 'growable' property, using MiniFrame
for properties panel, the panel is restored together with the
main window.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44630 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Roman Rolinsky
2007-03-07 14:45:12 +00:00
parent 69ce77e25a
commit 7df24e7868
6 changed files with 53 additions and 58 deletions

View File

@@ -311,11 +311,10 @@ class Frame(wx.Frame):
tree.RegisterKeyEvents()
# !!! frame styles are broken
# Miniframe for not embedded mode
miniFrame = wx.Frame(self, -1, 'Properties & Style',
(conf.panelX, conf.panelY),
(conf.panelWidth, conf.panelHeight))
# Miniframe for split mode
miniFrame = wx.MiniFrame(self, -1, 'Properties & Style',
(conf.panelX, conf.panelY),
(conf.panelWidth, conf.panelHeight))
self.miniFrame = miniFrame
sizer2 = wx.BoxSizer()
miniFrame.SetAutoLayout(True)
@@ -910,6 +909,7 @@ class Frame(wx.Frame):
self.miniFrame.Show(True)
self.miniFrame.SetDimensions(conf.panelX, conf.panelY,
conf.panelWidth, conf.panelHeight)
self.miniFrame.Layout()
# Reduce width
self.SetDimensions(pos.x, pos.y,
max(size.width - sizePanel.width, self.minWidth), size.height)
@@ -1285,14 +1285,18 @@ Homepage: http://xrced.sourceforge.net\
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()
if evt.Iconized():
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()
else:
conf.panelX, conf.panelY = self.miniFrame.GetPosition()
conf.panelWidth, conf.panelHeight = self.miniFrame.GetSize()
self.miniFrame.Iconize()
if not conf.embedPanel:
self.miniFrame.Iconize(False)
evt.Skip()
def OnCloseWindow(self, evt):