]> git.saurik.com Git - wxWidgets.git/commitdiff
wrapped up Show() calls to prevent gtk bug from manifesting
authorBenjamin Williams <bwilliams@kirix.com>
Mon, 31 Jul 2006 06:54:49 +0000 (06:54 +0000)
committerBenjamin Williams <bwilliams@kirix.com>
Mon, 31 Jul 2006 06:54:49 +0000 (06:54 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@40389 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/aui/framemanager.cpp

index 3314ec6e4c27d663828b20b8f0ea9542e1044f44..b97492d4378bbf6b0fa44457341717eb57bea7cf 100644 (file)
@@ -876,7 +876,9 @@ bool wxFrameManager::DetachPane(wxWindow* window)
 
                 // reduce flicker
                 p.window->SetSize(1,1);
-                p.frame->Show(false);
+
+                if (p.frame->IsShown())
+                    p.frame->Show(false);
 
                 // reparent to m_frame and destroy the pane
                 p.window->Reparent(m_frame);
@@ -1945,7 +1947,9 @@ void wxFrameManager::Update()
 
             // reduce flicker
             p.window->SetSize(1,1);
-            p.frame->Show(false);
+
+            if (p.frame->IsShown())
+                p.frame->Show(false);
 
             // reparent to m_frame and destroy the pane
             p.window->Reparent(m_frame);
@@ -1987,10 +1991,8 @@ void wxFrameManager::Update()
                 frame->SetPaneWindow(p);
                 p.frame = frame;
 
-                if (p.IsShown())
-                {
+                if (p.IsShown() && !frame->IsShown())
                     frame->Show();
-                }
             }
              else
             {
@@ -2010,7 +2012,8 @@ void wxFrameManager::Update()
         }
          else
         {
-            p.window->Show(p.IsShown());
+            if (p.window->IsShown() != p.IsShown())
+                p.window->Show(p.IsShown());
         }
 
         // if "active panes" are no longer allowed, clear
@@ -2724,7 +2727,8 @@ void wxFrameManager::HideHint()
     // hides a transparent window hint, if there is one
     if (m_hint_wnd)
     {
-        m_hint_wnd->Show(false);
+        if (m_hint_wnd->IsShown())
+            m_hint_wnd->Show(false);
 #if wxCHECK_VERSION(2,7,0)
         m_hint_wnd->SetTransparent(0);
 #else
@@ -2980,7 +2984,8 @@ void wxFrameManager::OnFloatingPaneClosed(wxWindow* wnd, wxCloseEvent& evt)
     {
         // reparent the pane window back to us and
         // prepare the frame window for destruction
-        pane.window->Show(false);
+        if (pane.window->IsShown())
+            pane.window->Show(false);
         pane.window->Reparent(m_frame);
         pane.frame = NULL;
         pane.Hide();