зеркало из https://github.com/mozilla/pjs.git
Don't let columns with no cells originating in them expand in the pass for expanding zero-width columns. b=425972 r=dholbert sr=roc a=blocking1.9+
This commit is contained in:
Родитель
bd068c001f
Коммит
dc126c4909
|
@ -0,0 +1,14 @@
|
|||
<html>
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<title>there should not be a red bar over the whole page</title>
|
||||
</head>
|
||||
<body >
|
||||
<table width="100%">
|
||||
<tbody>
|
||||
|
||||
<tr><td bgcolor="#ff3333" width="100%" height="50px"></td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,15 @@
|
|||
<html>
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<title>there should be a red bar over the whole page</title>
|
||||
</head>
|
||||
<body >
|
||||
<table width="100%">
|
||||
<tbody>
|
||||
|
||||
<tr><td bgcolor="#ff3333" width="1%" height="50px"></td></tr>
|
||||
<tr><td colspan="2"></td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,14 @@
|
|||
<html>
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<title>there should not be a red bar over the whole page</title>
|
||||
</head>
|
||||
<body >
|
||||
<table width="100%">
|
||||
<tbody>
|
||||
|
||||
<tr><td bgcolor="#ff3333" width="1%" height="50px"></td><td style="padding:0"> </td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,15 @@
|
|||
<html>
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<title>there should not be a red bar over the whole page</title>
|
||||
</head>
|
||||
<body >
|
||||
<table width="100%">
|
||||
<tbody>
|
||||
|
||||
<tr><td bgcolor="#ff3333" width="1%" height="50px"></td><td style="padding:0"></td></tr>
|
||||
<tr><td colspan="2"></td></tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
|
@ -792,4 +792,6 @@ fails-if(MOZ_WIDGET_TOOLKIT=="gtk2") == 424074-1-ref2.xul 424074-1-ref3.xul
|
|||
== 424434-1.html 424434-1-ref.html
|
||||
== 424631-1.html 424631-1-ref.html
|
||||
== 424710-1.html 424710-1-ref.html
|
||||
|
||||
== 425972-1.html 425972-1-ref.html
|
||||
== 425972-2.html 425972-2-ref.html
|
||||
!= 425972-1.html 425972-2.html
|
||||
|
|
|
@ -680,9 +680,10 @@ BasicTableLayoutStrategy::DistributeWidthToColumns(nscoord aWidth,
|
|||
* percent width have nonzero pref width, in proportion to pref
|
||||
* width [total_flex_pref]
|
||||
*
|
||||
* b. (NOTE: this case is for BTLS_FINAL_WIDTH only) otherwise, if any
|
||||
* columns without a specified coordinate width or percent width have
|
||||
* zero pref width, equally between these [numNonSpecZeroWidthCols]
|
||||
* b. (NOTE: this case is for BTLS_FINAL_WIDTH only) otherwise, if
|
||||
* any columns without a specified coordinate width or percent
|
||||
* width, but with cells originating in them have zero pref width,
|
||||
* equally between these [numNonSpecZeroWidthCols]
|
||||
*
|
||||
* c. otherwise, if any columns without percent width have nonzero
|
||||
* pref width, in proportion to pref width [total_fixed_pref]
|
||||
|
@ -739,7 +740,8 @@ BasicTableLayoutStrategy::DistributeWidthToColumns(nscoord aWidth,
|
|||
total_fixed_pref = NSCoordSaturatingAdd(total_fixed_pref,
|
||||
pref_width);
|
||||
} else if (pref_width == 0) {
|
||||
if (aWidthType == BTLS_FINAL_WIDTH) {
|
||||
if (aWidthType == BTLS_FINAL_WIDTH &&
|
||||
mTableFrame->GetNumCellsOriginatingInCol(col)) {
|
||||
++numNonSpecZeroWidthCols;
|
||||
}
|
||||
} else {
|
||||
|
@ -937,7 +939,8 @@ BasicTableLayoutStrategy::DistributeWidthToColumns(nscoord aWidth,
|
|||
"FLEX_FLEX_LARGE_ZERO only should be hit "
|
||||
"when we're setting final width.");
|
||||
if (pct == 0.0f &&
|
||||
!colFrame->GetHasSpecifiedCoord()) {
|
||||
!colFrame->GetHasSpecifiedCoord() &&
|
||||
mTableFrame->GetNumCellsOriginatingInCol(col)) {
|
||||
|
||||
NS_ASSERTION(col_width == 0 &&
|
||||
colFrame->GetPrefCoord() == 0,
|
||||
|
|
Загрузка…
Ссылка в новой задаче