зеркало из https://github.com/mozilla/gecko-dev.git
Bug 402893: don't scale up col prefWidth by % if it's nscoord_MAX. r+sr=roc, a=mtschrep
This commit is contained in:
Родитель
28c4fa48c7
Коммит
0d23f498fd
|
@ -611,8 +611,10 @@ BasicTableLayoutStrategy::ComputeIntrinsicWidths(nsIRenderingContext* aRendering
|
||||||
// intrinsic widths.
|
// intrinsic widths.
|
||||||
float p = colFrame->GetPrefPercent();
|
float p = colFrame->GetPrefPercent();
|
||||||
if (p > 0.0f) {
|
if (p > 0.0f) {
|
||||||
nscoord new_small_pct_expand =
|
nscoord colPref = colFrame->GetPrefCoord();
|
||||||
nscoord(float(colFrame->GetPrefCoord()) / p);
|
nscoord new_small_pct_expand =
|
||||||
|
(colPref == nscoord_MAX ?
|
||||||
|
nscoord_MAX : nscoord(float(colPref) / p));
|
||||||
if (new_small_pct_expand > max_small_pct_pref) {
|
if (new_small_pct_expand > max_small_pct_pref) {
|
||||||
max_small_pct_pref = new_small_pct_expand;
|
max_small_pct_pref = new_small_pct_expand;
|
||||||
}
|
}
|
||||||
|
|
Загрузка…
Ссылка в новой задаче