mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-01-30 10:12:59 +00:00
Fixed MapDeclarationInto() so it correctly handles 'min-width', 'max-width',
'min-height', and 'max-height'
This commit is contained in:
parent
bc8e5d3606
commit
c6c4afe1b6
@ -1853,16 +1853,16 @@ void MapDeclarationInto(nsICSSDeclaration* aDeclaration,
|
||||
}
|
||||
|
||||
SetCoord(ourPosition->mWidth, position->mWidth, SETCOORD_LPAH, font, aPresContext);
|
||||
SetCoord(ourPosition->mMinWidth, position->mWidth, SETCOORD_LPH, font, aPresContext);
|
||||
if (! SetCoord(ourPosition->mMaxWidth, position->mWidth, SETCOORD_LPH, font, aPresContext)) {
|
||||
SetCoord(ourPosition->mMinWidth, position->mMinWidth, SETCOORD_LPH, font, aPresContext);
|
||||
if (! SetCoord(ourPosition->mMaxWidth, position->mMaxWidth, SETCOORD_LPH, font, aPresContext)) {
|
||||
if (eCSSUnit_None == ourPosition->mMaxWidth.GetUnit()) {
|
||||
position->mMaxWidth.Reset();
|
||||
}
|
||||
}
|
||||
|
||||
SetCoord(ourPosition->mHeight, position->mHeight, SETCOORD_LPAH, font, aPresContext);
|
||||
SetCoord(ourPosition->mMinHeight, position->mHeight, SETCOORD_LPH, font, aPresContext);
|
||||
if (! SetCoord(ourPosition->mMaxHeight, position->mHeight, SETCOORD_LPH, font, aPresContext)) {
|
||||
SetCoord(ourPosition->mMinHeight, position->mMinHeight, SETCOORD_LPH, font, aPresContext);
|
||||
if (! SetCoord(ourPosition->mMaxHeight, position->mMaxHeight, SETCOORD_LPH, font, aPresContext)) {
|
||||
if (eCSSUnit_None == ourPosition->mMaxHeight.GetUnit()) {
|
||||
position->mMaxHeight.Reset();
|
||||
}
|
||||
|
@ -1853,16 +1853,16 @@ void MapDeclarationInto(nsICSSDeclaration* aDeclaration,
|
||||
}
|
||||
|
||||
SetCoord(ourPosition->mWidth, position->mWidth, SETCOORD_LPAH, font, aPresContext);
|
||||
SetCoord(ourPosition->mMinWidth, position->mWidth, SETCOORD_LPH, font, aPresContext);
|
||||
if (! SetCoord(ourPosition->mMaxWidth, position->mWidth, SETCOORD_LPH, font, aPresContext)) {
|
||||
SetCoord(ourPosition->mMinWidth, position->mMinWidth, SETCOORD_LPH, font, aPresContext);
|
||||
if (! SetCoord(ourPosition->mMaxWidth, position->mMaxWidth, SETCOORD_LPH, font, aPresContext)) {
|
||||
if (eCSSUnit_None == ourPosition->mMaxWidth.GetUnit()) {
|
||||
position->mMaxWidth.Reset();
|
||||
}
|
||||
}
|
||||
|
||||
SetCoord(ourPosition->mHeight, position->mHeight, SETCOORD_LPAH, font, aPresContext);
|
||||
SetCoord(ourPosition->mMinHeight, position->mHeight, SETCOORD_LPH, font, aPresContext);
|
||||
if (! SetCoord(ourPosition->mMaxHeight, position->mHeight, SETCOORD_LPH, font, aPresContext)) {
|
||||
SetCoord(ourPosition->mMinHeight, position->mMinHeight, SETCOORD_LPH, font, aPresContext);
|
||||
if (! SetCoord(ourPosition->mMaxHeight, position->mMaxHeight, SETCOORD_LPH, font, aPresContext)) {
|
||||
if (eCSSUnit_None == ourPosition->mMaxHeight.GetUnit()) {
|
||||
position->mMaxHeight.Reset();
|
||||
}
|
||||
|
@ -1853,16 +1853,16 @@ void MapDeclarationInto(nsICSSDeclaration* aDeclaration,
|
||||
}
|
||||
|
||||
SetCoord(ourPosition->mWidth, position->mWidth, SETCOORD_LPAH, font, aPresContext);
|
||||
SetCoord(ourPosition->mMinWidth, position->mWidth, SETCOORD_LPH, font, aPresContext);
|
||||
if (! SetCoord(ourPosition->mMaxWidth, position->mWidth, SETCOORD_LPH, font, aPresContext)) {
|
||||
SetCoord(ourPosition->mMinWidth, position->mMinWidth, SETCOORD_LPH, font, aPresContext);
|
||||
if (! SetCoord(ourPosition->mMaxWidth, position->mMaxWidth, SETCOORD_LPH, font, aPresContext)) {
|
||||
if (eCSSUnit_None == ourPosition->mMaxWidth.GetUnit()) {
|
||||
position->mMaxWidth.Reset();
|
||||
}
|
||||
}
|
||||
|
||||
SetCoord(ourPosition->mHeight, position->mHeight, SETCOORD_LPAH, font, aPresContext);
|
||||
SetCoord(ourPosition->mMinHeight, position->mHeight, SETCOORD_LPH, font, aPresContext);
|
||||
if (! SetCoord(ourPosition->mMaxHeight, position->mHeight, SETCOORD_LPH, font, aPresContext)) {
|
||||
SetCoord(ourPosition->mMinHeight, position->mMinHeight, SETCOORD_LPH, font, aPresContext);
|
||||
if (! SetCoord(ourPosition->mMaxHeight, position->mMaxHeight, SETCOORD_LPH, font, aPresContext)) {
|
||||
if (eCSSUnit_None == ourPosition->mMaxHeight.GetUnit()) {
|
||||
position->mMaxHeight.Reset();
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user