зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1134744 - Fix baseline for form controls when line is inverted relative to block dir. r=smontagu
This commit is contained in:
Родитель
e673083ef6
Коммит
4c781f24a6
|
@ -70,9 +70,13 @@ nsFormControlFrame::GetLogicalBaseline(WritingMode aWritingMode) const
|
||||||
NS_ASSERTION(!NS_SUBTREE_DIRTY(this),
|
NS_ASSERTION(!NS_SUBTREE_DIRTY(this),
|
||||||
"frame must not be dirty");
|
"frame must not be dirty");
|
||||||
// Treat radio buttons and checkboxes as having an intrinsic baseline
|
// Treat radio buttons and checkboxes as having an intrinsic baseline
|
||||||
// at the bottom of the control (use the bottom content edge rather
|
// at the block-end of the control (use the block-end content edge rather
|
||||||
// than the bottom margin edge).
|
// than the margin edge).
|
||||||
return BSize(aWritingMode) -
|
// For "inverted" lines (typically in writing-mode:vertical-lr), use the
|
||||||
|
// block-start end instead.
|
||||||
|
return aWritingMode.IsLineInverted()
|
||||||
|
? GetLogicalUsedBorderAndPadding(aWritingMode).BStart(aWritingMode)
|
||||||
|
: BSize(aWritingMode) -
|
||||||
GetLogicalUsedBorderAndPadding(aWritingMode).BEnd(aWritingMode);
|
GetLogicalUsedBorderAndPadding(aWritingMode).BEnd(aWritingMode);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Загрузка…
Ссылка в новой задаче