mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-26 22:32:46 +00:00
Added namespace ID to the AttributeChanged notification
Part of the fix for Bug 15153 r=troy
This commit is contained in:
parent
a6adfea707
commit
d168caadef
@ -2477,7 +2477,7 @@ RDFElementImpl::SetAttribute(PRInt32 aNameSpaceID,
|
||||
}
|
||||
|
||||
if (NS_SUCCEEDED(rv) && aNotify && ElementIsInDocument()) {
|
||||
mDocument->AttributeChanged(NS_STATIC_CAST(nsIStyledContent*, this), aName, NS_STYLE_HINT_UNKNOWN);
|
||||
mDocument->AttributeChanged(NS_STATIC_CAST(nsIStyledContent*, this), aNameSpaceID, aName, NS_STYLE_HINT_UNKNOWN);
|
||||
}
|
||||
|
||||
return rv;
|
||||
@ -2699,7 +2699,7 @@ RDFElementImpl::UnsetAttribute(PRInt32 aNameSpaceID, nsIAtom* aName, PRBool aNot
|
||||
// Notify document
|
||||
if (NS_SUCCEEDED(rv) && aNotify && (nsnull != mDocument)) {
|
||||
mDocument->AttributeChanged(NS_STATIC_CAST(nsIStyledContent*, this),
|
||||
aName,
|
||||
aNameSpaceID, aName,
|
||||
NS_STYLE_HINT_UNKNOWN);
|
||||
}
|
||||
}
|
||||
|
@ -301,6 +301,7 @@ public:
|
||||
NS_IMETHOD ContentStatesChanged(nsIContent* aContent1, nsIContent* aContent2);
|
||||
|
||||
NS_IMETHOD AttributeChanged(nsIContent* aChild,
|
||||
PRInt32 aNameSpaceID,
|
||||
nsIAtom* aAttribute,
|
||||
PRInt32 aHint); // See nsStyleConsts fot hint values
|
||||
|
||||
@ -1700,6 +1701,7 @@ XULDocumentImpl::ContentStatesChanged(nsIContent* aContent1, nsIContent* aConten
|
||||
|
||||
NS_IMETHODIMP
|
||||
XULDocumentImpl::AttributeChanged(nsIContent* aElement,
|
||||
PRInt32 aNameSpaceID,
|
||||
nsIAtom* aAttribute,
|
||||
PRInt32 aHint)
|
||||
{
|
||||
@ -1724,7 +1726,7 @@ XULDocumentImpl::AttributeChanged(nsIContent* aElement,
|
||||
// Now notify external observers
|
||||
for (PRInt32 i = 0; i < mObservers.Count(); i++) {
|
||||
nsIDocumentObserver* observer = (nsIDocumentObserver*)mObservers[i];
|
||||
observer->AttributeChanged(this, aElement, aAttribute, aHint);
|
||||
observer->AttributeChanged(this, aElement, aNameSpaceID, aAttribute, aHint);
|
||||
if (observer != (nsIDocumentObserver*)mObservers.ElementAt(i)) {
|
||||
i--;
|
||||
}
|
||||
|
@ -2477,7 +2477,7 @@ RDFElementImpl::SetAttribute(PRInt32 aNameSpaceID,
|
||||
}
|
||||
|
||||
if (NS_SUCCEEDED(rv) && aNotify && ElementIsInDocument()) {
|
||||
mDocument->AttributeChanged(NS_STATIC_CAST(nsIStyledContent*, this), aName, NS_STYLE_HINT_UNKNOWN);
|
||||
mDocument->AttributeChanged(NS_STATIC_CAST(nsIStyledContent*, this), aNameSpaceID, aName, NS_STYLE_HINT_UNKNOWN);
|
||||
}
|
||||
|
||||
return rv;
|
||||
@ -2699,7 +2699,7 @@ RDFElementImpl::UnsetAttribute(PRInt32 aNameSpaceID, nsIAtom* aName, PRBool aNot
|
||||
// Notify document
|
||||
if (NS_SUCCEEDED(rv) && aNotify && (nsnull != mDocument)) {
|
||||
mDocument->AttributeChanged(NS_STATIC_CAST(nsIStyledContent*, this),
|
||||
aName,
|
||||
aNameSpaceID, aName,
|
||||
NS_STYLE_HINT_UNKNOWN);
|
||||
}
|
||||
}
|
||||
|
@ -301,6 +301,7 @@ public:
|
||||
NS_IMETHOD ContentStatesChanged(nsIContent* aContent1, nsIContent* aContent2);
|
||||
|
||||
NS_IMETHOD AttributeChanged(nsIContent* aChild,
|
||||
PRInt32 aNameSpaceID,
|
||||
nsIAtom* aAttribute,
|
||||
PRInt32 aHint); // See nsStyleConsts fot hint values
|
||||
|
||||
@ -1700,6 +1701,7 @@ XULDocumentImpl::ContentStatesChanged(nsIContent* aContent1, nsIContent* aConten
|
||||
|
||||
NS_IMETHODIMP
|
||||
XULDocumentImpl::AttributeChanged(nsIContent* aElement,
|
||||
PRInt32 aNameSpaceID,
|
||||
nsIAtom* aAttribute,
|
||||
PRInt32 aHint)
|
||||
{
|
||||
@ -1724,7 +1726,7 @@ XULDocumentImpl::AttributeChanged(nsIContent* aElement,
|
||||
// Now notify external observers
|
||||
for (PRInt32 i = 0; i < mObservers.Count(); i++) {
|
||||
nsIDocumentObserver* observer = (nsIDocumentObserver*)mObservers[i];
|
||||
observer->AttributeChanged(this, aElement, aAttribute, aHint);
|
||||
observer->AttributeChanged(this, aElement, aNameSpaceID, aAttribute, aHint);
|
||||
if (observer != (nsIDocumentObserver*)mObservers.ElementAt(i)) {
|
||||
i--;
|
||||
}
|
||||
|
@ -2477,7 +2477,7 @@ RDFElementImpl::SetAttribute(PRInt32 aNameSpaceID,
|
||||
}
|
||||
|
||||
if (NS_SUCCEEDED(rv) && aNotify && ElementIsInDocument()) {
|
||||
mDocument->AttributeChanged(NS_STATIC_CAST(nsIStyledContent*, this), aName, NS_STYLE_HINT_UNKNOWN);
|
||||
mDocument->AttributeChanged(NS_STATIC_CAST(nsIStyledContent*, this), aNameSpaceID, aName, NS_STYLE_HINT_UNKNOWN);
|
||||
}
|
||||
|
||||
return rv;
|
||||
@ -2699,7 +2699,7 @@ RDFElementImpl::UnsetAttribute(PRInt32 aNameSpaceID, nsIAtom* aName, PRBool aNot
|
||||
// Notify document
|
||||
if (NS_SUCCEEDED(rv) && aNotify && (nsnull != mDocument)) {
|
||||
mDocument->AttributeChanged(NS_STATIC_CAST(nsIStyledContent*, this),
|
||||
aName,
|
||||
aNameSpaceID, aName,
|
||||
NS_STYLE_HINT_UNKNOWN);
|
||||
}
|
||||
}
|
||||
|
@ -1377,6 +1377,7 @@ NS_IMETHODIMP
|
||||
nsMenu::AttributeChanged(
|
||||
nsIDocument * aDocument,
|
||||
nsIContent * aContent,
|
||||
PRInt32 aNameSpaceID,
|
||||
nsIAtom * aAttribute,
|
||||
PRInt32 aHint)
|
||||
{
|
||||
|
@ -106,6 +106,7 @@ public:
|
||||
nsIContent* aContent2);
|
||||
NS_IMETHOD AttributeChanged(nsIDocument *aDocument,
|
||||
nsIContent* aContent,
|
||||
PRInt32 aNameSpaceID,
|
||||
nsIAtom* aAttribute,
|
||||
PRInt32 aHint);
|
||||
NS_IMETHOD ContentAppended(nsIDocument *aDocument,
|
||||
|
@ -2460,6 +2460,7 @@ nsWebShellWindow::ContentStatesChanged(nsIDocument *aDocument,
|
||||
NS_IMETHODIMP
|
||||
nsWebShellWindow::AttributeChanged(nsIDocument *aDocument,
|
||||
nsIContent* aContent,
|
||||
PRInt32 aNameSpaceID,
|
||||
nsIAtom* aAttribute,
|
||||
PRInt32 aHint)
|
||||
{
|
||||
|
@ -197,6 +197,7 @@ public:
|
||||
nsIContent* aContent2);
|
||||
NS_IMETHOD AttributeChanged(nsIDocument *aDocument,
|
||||
nsIContent* aContent,
|
||||
PRInt32 aNameSpaceID,
|
||||
nsIAtom* aAttribute,
|
||||
PRInt32 aHint);
|
||||
NS_IMETHOD ContentAppended(nsIDocument *aDocument,
|
||||
|
Loading…
Reference in New Issue
Block a user