Merged sizer fix from stable branch

Added support for transparent wxImage::Paste()


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@8206 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robert Roebling
2000-08-29 08:55:40 +00:00
parent 6a2c187404
commit aa21b5090a
2 changed files with 34 additions and 13 deletions

View File

@@ -897,28 +897,22 @@ wxSize wxBoxSizer::CalcMin()
{
wxSizerItem *item = (wxSizerItem*) node->Data();
int weight = 1;
if (item->GetOption())
weight = item->GetOption();
m_stretchable += item->GetOption();
wxSize size( item->CalcMin() );
if (m_orient == wxHORIZONTAL)
{
m_minWidth += (size.x * weight);
m_minWidth += size.x;
m_minHeight = wxMax( m_minHeight, size.y );
}
else
{
m_minHeight += (size.y * weight);
m_minHeight += size.y;
m_minWidth = wxMax( m_minWidth, size.x );
}
if (item->GetOption())
{
m_stretchable += weight;
}
else
if (item->GetOption() == 0)
{
if (m_orient == wxVERTICAL)
{
@@ -926,7 +920,7 @@ wxSize wxBoxSizer::CalcMin()
m_fixedWidth = wxMax( m_fixedWidth, size.x );
}
else
{
{
m_fixedWidth += size.x;
m_fixedHeight = wxMax( m_fixedHeight, size.y );
}