allocate size for the extra controls in the file dialog (#9679)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@58270 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2009-01-21 15:32:02 +00:00
parent 14fd5e968b
commit 6fa6d65956
5 changed files with 82 additions and 4 deletions

View File

@@ -168,6 +168,18 @@ bool wxFileDialogBase::CreateExtraControl()
return true;
}
wxSize wxFileDialogBase::GetExtraControlSize()
{
if ( !m_extraControlCreator )
return wxDefaultSize;
// create the extra control in an empty dialog just to find its size: this
// is not terribly efficient but we do need to know the size before
// creating the native dialog and this seems to be the only way
wxDialog dlg(NULL, wxID_ANY, "");
return (*m_extraControlCreator)(&dlg)->GetSize();
}
//----------------------------------------------------------------------------
// wxFileDialog convenience functions
//----------------------------------------------------------------------------