Bug 578696 part 5. Stop holding strong refs when calling CharacterDataWillChange. r=sicking

This commit is contained in:
Boris Zbarsky 2010-07-21 11:33:32 -04:00
parent b8256cdb51
commit 76ef6dec31
2 changed files with 7 additions and 1 deletions

View File

@ -117,6 +117,12 @@ public:
* @param aDocument The owner-document of aContent. Can be null.
* @param aContent The piece of content that changed. Is never null.
* @param aInfo The structure with information details about the change.
*
* @note Callers of this method might not hold a strong reference to the
* observer. The observer is responsible for making sure it stays
* alive for the duration of the call as needed. The observer may
* assume that this call will happen when there are script blockers on
* the stack.
*/
virtual void CharacterDataWillChange(nsIDocument *aDocument,
nsIContent* aContent,

View File

@ -114,7 +114,7 @@ nsNodeUtils::CharacterDataWillChange(nsIContent* aContent,
CharacterDataChangeInfo* aInfo)
{
nsIDocument* doc = aContent->GetOwnerDoc();
IMPL_STRONGREF_MUTATION_NOTIFICATION(CharacterDataWillChange, aContent,
IMPL_MUTATION_NOTIFICATION(CharacterDataWillChange, aContent,
(doc, aContent, aInfo));
}