to force pane resizing _before_ showing the window.
Added a call to UpdateSize from helpfrm.cpp. Without
this, the flicker is horrible.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@26333
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
// parameter should be NULL)
bool ReplaceWindow(wxWindow *winOld, wxWindow *winNew);
+ // Make sure the child window sizes are updated. This is useful
+ // for reducing flicker by updating the sizes before a
+ // window is shown, if you know the overall size is correct.
+ void UpdateSize();
+
// Is the window split?
bool IsSplit() const { return (m_windowTwo != NULL); }
}
}
+// Make sure the child window sizes are updated. This is useful
+// for reducing flicker by updating the sizes before a
+// window is shown, if you know the overall size is correct.
+void wxSplitterWindow::UpdateSize()
+{
+ m_checkRequestedSashPosition = true;
+ SizeWindows();
+ m_checkRequestedSashPosition = false;
+}
+
bool wxSplitterWindow::DoSendEvent(wxSplitterEvent& event)
{
return !GetEventHandler()->ProcessEvent(event) || event.IsAllowed();
m_helpFrame->Create(NULL, wxID_HTML_HELPFRAME, wxEmptyString, m_FrameStyle);
m_helpFrame->SetTitleFormat(m_titleFormat);
+
m_helpFrame->Show(TRUE);
}
}
}
+ // Reduce flicker by updating the splitter pane sizes before the
+ // frame is shown
+ wxSizeEvent sizeEvent(GetSize(), GetId());
+ ProcessEvent(sizeEvent);
+
+ m_Splitter->UpdateSize();
+
return TRUE;
}