Added wxFIXED_SIZE.
Propogated wxSizer::SetItemMinSize to SetSizeHints for window items. Updated docs for flag parameter to be more readable and understandable. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@26644 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -193,7 +193,7 @@ wxSize wxSizerItem::CalcMin()
|
||||
}
|
||||
else
|
||||
{
|
||||
if ( IsWindow() )
|
||||
if ( IsWindow() && !(m_flag & wxFIXED_SIZE) )
|
||||
{
|
||||
// the size of the window may change during run-time, we should
|
||||
// use the current minimal size
|
||||
@@ -736,6 +736,7 @@ bool wxSizer::DoSetItemMinSize( wxWindow *window, int width, int height )
|
||||
if (item->GetWindow() == window)
|
||||
{
|
||||
item->SetInitSize( width, height );
|
||||
item->GetWindow()->SetSizeHints(width, height);
|
||||
return true;
|
||||
}
|
||||
node = node->GetNext();
|
||||
@@ -815,6 +816,8 @@ bool wxSizer::DoSetItemMinSize( size_t index, int width, int height )
|
||||
{
|
||||
// ... but the minimal size of spacers and windows in stored in them
|
||||
item->SetInitSize( width, height );
|
||||
if (item->GetWindow())
|
||||
item->GetWindow()->SetSizeHints(width, height);
|
||||
}
|
||||
|
||||
return true;
|
||||
|
Reference in New Issue
Block a user