mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-04 21:18:35 +00:00
if the size attr is ever evaled less than 1 then it is set to 1
b=46224, r=kmcclusk
This commit is contained in:
parent
425d7a8ef8
commit
bf1a712ea4
@ -2002,6 +2002,22 @@ nsGfxTextControlFrame2::GetSizeFromContent(PRInt32* aSize) const
|
||||
}
|
||||
NS_RELEASE(content);
|
||||
}
|
||||
if (*aSize < 1) {
|
||||
// This is part of bug 46224
|
||||
// when we can get a PresContent (may be cache it)
|
||||
// then we can check the compatibility mode
|
||||
#ifdef FUTURE_ADDITIONAL_FIX_FOR_46224
|
||||
nsCompatibility mode;
|
||||
mPresContext->GetCompatibilityMode(&mode);
|
||||
if (eCompatibility_NavQuirks == mode) {
|
||||
*aSize = 1;
|
||||
} else {
|
||||
*aSize = 20;
|
||||
}
|
||||
#else
|
||||
*aSize = 1;
|
||||
#endif
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user