From: Julian Smart Date: Tue, 13 Mar 2012 08:42:03 +0000 (+0000) Subject: Fixed size calculation X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/a64f38d67431a068d6c08b54500527dde04ed703 Fixed size calculation git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70891 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/ribbon/panel.cpp b/src/ribbon/panel.cpp index f8f26f1e89..91c014e414 100644 --- a/src/ribbon/panel.cpp +++ b/src/ribbon/panel.cpp @@ -321,7 +321,8 @@ wxSize wxRibbonPanel::GetBestSizeForParentSize(const wxSize& parentSize) const if (control) { wxClientDC temp_dc((wxRibbonPanel*) this); - wxSize childSize = control->GetBestSizeForParentSize(parentSize); + wxSize clientParentSize = m_art->GetPanelClientSize(temp_dc, this, parentSize, NULL); + wxSize childSize = control->GetBestSizeForParentSize(clientParentSize); wxSize overallSize = m_art->GetPanelSize(temp_dc, this, childSize, NULL); return overallSize; }