Removed code that was causing a reframe when the class of an element changed. This is unnecessary and causes performance problems (reframes are expensive). b=21225 r=dcone,pierre
git-svn-id: svn://10.0.0.236/trunk@63187 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
0a2d8b73d0
commit
39a3c92b6b
@ -1537,7 +1537,7 @@ nsGenericHTMLElement::SizeOf(nsISizeOfHandler* aSizer, PRUint32* aResult,
|
||||
sum += (PRUint32) aInstanceSize;
|
||||
if (mAttributes) {
|
||||
PRUint32 attrs = 0;
|
||||
mAttributes->SizeOf(aSizer, &attrs);
|
||||
mAttributes->SizeOf(aSizer, attrs);
|
||||
sum += attrs;
|
||||
}
|
||||
#endif
|
||||
@ -2416,10 +2416,18 @@ nsGenericHTMLElement::GetCommonMappedAttributesImpact(const nsIAtom* aAttribute,
|
||||
aHint = NS_STYLE_HINT_REFLOW; // XXX really? possibly FRAMECHANGE?
|
||||
return PR_TRUE;
|
||||
}
|
||||
/*
|
||||
We should not REFRAME for a class change;
|
||||
let the resulting style decide the impact
|
||||
(bug 21225, mja)
|
||||
*/
|
||||
#if 0
|
||||
else if (nsHTMLAtoms::kClass == aAttribute) { // bug 8862
|
||||
aHint = NS_STYLE_HINT_FRAMECHANGE;
|
||||
return PR_TRUE;
|
||||
}
|
||||
#endif
|
||||
|
||||
else if (nsHTMLAtoms::_baseHref == aAttribute) {
|
||||
aHint = NS_STYLE_HINT_VISUAL; // at a minimum, elements may need to override
|
||||
return PR_TRUE;
|
||||
|
||||
@ -1537,7 +1537,7 @@ nsGenericHTMLElement::SizeOf(nsISizeOfHandler* aSizer, PRUint32* aResult,
|
||||
sum += (PRUint32) aInstanceSize;
|
||||
if (mAttributes) {
|
||||
PRUint32 attrs = 0;
|
||||
mAttributes->SizeOf(aSizer, &attrs);
|
||||
mAttributes->SizeOf(aSizer, attrs);
|
||||
sum += attrs;
|
||||
}
|
||||
#endif
|
||||
@ -2416,10 +2416,18 @@ nsGenericHTMLElement::GetCommonMappedAttributesImpact(const nsIAtom* aAttribute,
|
||||
aHint = NS_STYLE_HINT_REFLOW; // XXX really? possibly FRAMECHANGE?
|
||||
return PR_TRUE;
|
||||
}
|
||||
/*
|
||||
We should not REFRAME for a class change;
|
||||
let the resulting style decide the impact
|
||||
(bug 21225, mja)
|
||||
*/
|
||||
#if 0
|
||||
else if (nsHTMLAtoms::kClass == aAttribute) { // bug 8862
|
||||
aHint = NS_STYLE_HINT_FRAMECHANGE;
|
||||
return PR_TRUE;
|
||||
}
|
||||
#endif
|
||||
|
||||
else if (nsHTMLAtoms::_baseHref == aAttribute) {
|
||||
aHint = NS_STYLE_HINT_VISUAL; // at a minimum, elements may need to override
|
||||
return PR_TRUE;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user