mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-27 04:05:32 +00:00
Fix for dogfood bug 41027 -r hyatt
This commit is contained in:
parent
6c56f39224
commit
4401bea579
@ -326,8 +326,13 @@ nsSprocketLayout::Layout(nsIBox* aBox, nsBoxLayoutState& aState)
|
||||
PRBool layout = PR_TRUE;
|
||||
|
||||
child->GetMargin(margin);
|
||||
if (childRect.width >= margin.left + margin.right && childRect.height >= margin.top + margin.bottom)
|
||||
childRect.Deflate(margin);
|
||||
//if (childRect.width >= margin.left + margin.right && childRect.height >= margin.top + margin.bottom)
|
||||
childRect.Deflate(margin);
|
||||
|
||||
if (childRect.width < 0)
|
||||
childRect.width = 0;
|
||||
if (childRect.height < 0)
|
||||
childRect.height = 0;
|
||||
|
||||
if (passes > 0) {
|
||||
layout = PR_FALSE;
|
||||
|
@ -232,6 +232,12 @@ nsStackLayout::Layout(nsIBox* aBox, nsBoxLayoutState& aState)
|
||||
child->GetMargin(margin);
|
||||
nsRect childRect(clientRect);
|
||||
childRect.Deflate(margin);
|
||||
|
||||
if (childRect.width < 0)
|
||||
childRect.width = 0;
|
||||
if (childRect.height < 0)
|
||||
childRect.height = 0;
|
||||
|
||||
child->SetBounds(aState, childRect);
|
||||
child->Layout(aState);
|
||||
child->GetBounds(childRect);
|
||||
|
Loading…
Reference in New Issue
Block a user