mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-28 11:28:38 +00:00
Fix XUL style attribute change regression by making |#ifdef MOZ_SVG| code the default, but moved elsewhere. b=163481 r=bbaetz sr=bryner
This commit is contained in:
parent
e1b0de1025
commit
8580076d1f
@ -10732,12 +10732,6 @@ nsCSSFrameConstructor::AttributeChanged(nsIPresContext* aPresContext,
|
||||
shell->GetFrameManager(getter_AddRefs(frameManager));
|
||||
|
||||
PRBool affects;
|
||||
#ifdef MOZ_SVG
|
||||
// XXX should check we're in SVG NS here
|
||||
if (aAttribute == nsHTMLAtoms::style)
|
||||
affects = PR_TRUE;
|
||||
else
|
||||
#endif
|
||||
frameManager->AttributeAffectsStyle(aAttribute, aContent, affects);
|
||||
if (affects) {
|
||||
#ifdef DEBUG_shaver
|
||||
|
@ -2011,6 +2011,13 @@ FrameManager::AttributeAffectsStyle(nsIAtom *aAttribute, nsIContent *aContent,
|
||||
nsresult rv = NS_OK;
|
||||
NS_ENSURE_TRUE(mPresShell, NS_ERROR_NOT_AVAILABLE);
|
||||
|
||||
if (aAttribute == nsHTMLAtoms::style) {
|
||||
// Perhaps should check that it's XUL, SVG, (or HTML) namespace, but
|
||||
// it doesn't really matter.
|
||||
aAffects = PR_TRUE;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
nsCOMPtr<nsIXMLContent> xml(do_QueryInterface(aContent));
|
||||
if (xml) {
|
||||
rv = mStyleSet->AttributeAffectsStyle(aAttribute, aContent, aAffects);
|
||||
|
@ -2011,6 +2011,13 @@ FrameManager::AttributeAffectsStyle(nsIAtom *aAttribute, nsIContent *aContent,
|
||||
nsresult rv = NS_OK;
|
||||
NS_ENSURE_TRUE(mPresShell, NS_ERROR_NOT_AVAILABLE);
|
||||
|
||||
if (aAttribute == nsHTMLAtoms::style) {
|
||||
// Perhaps should check that it's XUL, SVG, (or HTML) namespace, but
|
||||
// it doesn't really matter.
|
||||
aAffects = PR_TRUE;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
nsCOMPtr<nsIXMLContent> xml(do_QueryInterface(aContent));
|
||||
if (xml) {
|
||||
rv = mStyleSet->AttributeAffectsStyle(aAttribute, aContent, aAffects);
|
||||
|
@ -10732,12 +10732,6 @@ nsCSSFrameConstructor::AttributeChanged(nsIPresContext* aPresContext,
|
||||
shell->GetFrameManager(getter_AddRefs(frameManager));
|
||||
|
||||
PRBool affects;
|
||||
#ifdef MOZ_SVG
|
||||
// XXX should check we're in SVG NS here
|
||||
if (aAttribute == nsHTMLAtoms::style)
|
||||
affects = PR_TRUE;
|
||||
else
|
||||
#endif
|
||||
frameManager->AttributeAffectsStyle(aAttribute, aContent, affects);
|
||||
if (affects) {
|
||||
#ifdef DEBUG_shaver
|
||||
|
Loading…
Reference in New Issue
Block a user