[Date Prev][Date Next][Thread Prev][Thread Next][Thread Index]
[XaraXtreme-commits] Commit Complete
Commit by : alex
Repository : xara
Revision : 840
Date : Wed Apr 19 15:51:10 BST 2006
Changed paths:
M /Trunk/XaraLX/wxXtra/manager.cpp
Pane deletion fix
Diff:
Index: Trunk/XaraLX/wxXtra/manager.cpp
===================================================================
--- Trunk/XaraLX/wxXtra/manager.cpp (revision 839)
+++ Trunk/XaraLX/wxXtra/manager.cpp (revision 840)
@@ -1535,6 +1535,26 @@
{
if (m_panes.Item(i).window == window)
{
+
+ wxPaneInfo& p = m_panes.Item(i);
+
+ if (p.frame)
+ {
+ // we have a floating frame, so we need to
+ // reparent it to m_frame and destroy the floating frame
+
+ // reduce flicker - we assume the caller will resize the denuded window
+
+ p.window->SetSize(1,1);
+ p.frame->Show(false);
+
+ // reparent to m_frame and destroy the pane
+ p.window->Reparent(m_frame);
+ p.frame->SetSizer(NULL);
+ p.frame->Destroy();
+ p.frame = NULL;
+ }
+
m_panes.RemoveAt(i);
return true;
}
Xara