Bug 617300 - pend accessible recreation on attribute change if necessary, r=davidb, a=blockingBetaN
authorAlexander Surkov <surkov.alexander@gmail.com>
Wed, 19 Jan 2011 16:03:12 +0800
changeset 60851 e807269acaa316f55dbfa2b54a1e85db84c5f751
parent 60850 f878d0aaf9f001fb10ddae16032fcb837c280d56
child 60852 9163f9b80bce2c68446229b7a71bf8a127957bed
push id18136
push usersurkov.alexander@gmail.com
push dateWed, 19 Jan 2011 08:04:32 +0000
treeherdermozilla-central@e807269acaa3 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersdavidb, blockingBetaN
bugs617300
milestone2.0b10pre
first release with
nightly linux32
e807269acaa3 / 4.0b10pre / 20110119030331 / files
nightly linux64
e807269acaa3 / 4.0b10pre / 20110119030331 / files
nightly mac
e807269acaa3 / 4.0b10pre / 20110119030331 / files
nightly win32
e807269acaa3 / 4.0b10pre / 20110119030331 / files
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
releases
nightly linux32
nightly linux64
nightly mac
nightly win32
Bug 617300 - pend accessible recreation on attribute change if necessary, r=davidb, a=blockingBetaN
accessible/src/base/nsDocAccessible.cpp
--- a/accessible/src/base/nsDocAccessible.cpp
+++ b/accessible/src/base/nsDocAccessible.cpp
@@ -1641,35 +1641,41 @@ nsDocAccessible::UpdateAccessibleOnAttrC
     if (mContent == aElement) {
       SetRoleMapEntry(nsAccUtils::GetRoleMapEntry(aElement));
       return true;
     }
 
     // Recreate the accessible when role is changed because we might require a
     // different accessible class for the new role or the accessible may expose
     // a different sets of interfaces (COM restriction).
-    RecreateAccessible(aElement);
+    HandleNotification<nsDocAccessible, nsINode>
+      (this, &nsDocAccessible::RecreateAccessible, aElement);
+
     return true;
   }
 
   if (aAttribute == nsAccessibilityAtoms::href ||
       aAttribute == nsAccessibilityAtoms::onclick) {
     // Not worth the expense to ensure which namespace these are in
     // It doesn't kill use to recreate the accessible even if the attribute was used
     // in the wrong namespace or an element that doesn't support it
-    RecreateAccessible(aElement);
+    HandleNotification<nsDocAccessible, nsINode>
+      (this, &nsDocAccessible::RecreateAccessible, aElement);
+
     return true;
   }
 
   if (aAttribute == nsAccessibilityAtoms::aria_multiselectable &&
       aElement->HasAttr(kNameSpaceID_None, nsAccessibilityAtoms::role)) {
     // This affects whether the accessible supports SelectAccessible.
     // COM says we cannot change what interfaces are supported on-the-fly,
     // so invalidate this object. A new one will be created on demand.
-    RecreateAccessible(aElement);
+    HandleNotification<nsDocAccessible, nsINode>
+      (this, &nsDocAccessible::RecreateAccessible, aElement);
+
     return true;
   }
 
   return false;
 }
 
 void
 nsDocAccessible::FireValueChangeForTextFields(nsAccessible *aAccessible)