зеркало из https://github.com/mozilla/gecko-dev.git
Make nsIFrame::GetOrdinal accept all values that the CSS parser accepts (which currently adds no values). (Bug 644514 patch 1) r=bzbarsky
This commit is contained in:
Родитель
f69222ff51
Коммит
6f5580985e
|
@ -514,8 +514,9 @@ nsBox::GetFlex(nsBoxLayoutState& aState)
|
|||
PRUint32
|
||||
nsIFrame::GetOrdinal(nsBoxLayoutState& aState)
|
||||
{
|
||||
PRUint32 ordinal = DEFAULT_ORDINAL_GROUP;
|
||||
PRUint32 ordinal = GetStyleXUL()->mBoxOrdinal;
|
||||
|
||||
// When present, attribute value overrides CSS.
|
||||
nsIContent* content = GetContent();
|
||||
if (content) {
|
||||
PRInt32 error;
|
||||
|
@ -525,14 +526,6 @@ nsIFrame::GetOrdinal(nsBoxLayoutState& aState)
|
|||
if (!value.IsEmpty()) {
|
||||
ordinal = value.ToInteger(&error);
|
||||
}
|
||||
else {
|
||||
// No attribute value. Check CSS.
|
||||
const nsStyleXUL* boxInfo = GetStyleXUL();
|
||||
if (boxInfo->mBoxOrdinal > 1) {
|
||||
// The ordinal group was defined in CSS.
|
||||
ordinal = (nscoord)boxInfo->mBoxOrdinal;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return ordinal;
|
||||
|
|
Загрузка…
Ссылка в новой задаче