зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1392993 - Change nsIAccessibleObjectAttributeChangedEvent.changedAttribute from an nsIAtom to an AString. r=MarcoZ.
This removes one use of nsIAtom within scripts, which is good (see bug 1392883). All the uses of this attribute within scripts just converted it to a string anyway. --HG-- extra : rebase_source : 080c12506722df5d18e78659bbb922421baa5b80
This commit is contained in:
Родитель
bbc0805e28
Коммит
eb53891d73
|
@ -258,11 +258,13 @@ a11y::MakeXPCEvent(AccEvent* aEvent)
|
|||
|
||||
if (eventGroup & (1 << AccEvent::eObjectAttrChangedEvent)) {
|
||||
AccObjectAttrChangedEvent* oac = downcast_accEvent(aEvent);
|
||||
nsString attribute;
|
||||
oac->GetAttribute()->ToString(attribute);
|
||||
xpEvent = new xpcAccObjectAttributeChangedEvent(type,
|
||||
ToXPC(acc),
|
||||
ToXPCDocument(doc), domNode,
|
||||
fromUser,
|
||||
oac->GetAttribute());
|
||||
attribute);
|
||||
return xpEvent.forget();
|
||||
}
|
||||
|
||||
|
|
|
@ -6,8 +6,6 @@
|
|||
|
||||
#include "nsIAccessibleEvent.idl"
|
||||
|
||||
interface nsIAtom;
|
||||
|
||||
/**
|
||||
* Fired when an attribute of an accessible changes.
|
||||
*/
|
||||
|
@ -17,5 +15,5 @@ interface nsIAccessibleObjectAttributeChangedEvent : nsIAccessibleEvent
|
|||
/**
|
||||
* Return the accessible attribute that changed.
|
||||
*/
|
||||
readonly attribute nsIAtom changedAttribute;
|
||||
readonly attribute AString changedAttribute;
|
||||
};
|
||||
|
|
|
@ -232,7 +232,7 @@ this.EventManager.prototype = {
|
|||
{
|
||||
let evt = aEvent.QueryInterface(
|
||||
Ci.nsIAccessibleObjectAttributeChangedEvent);
|
||||
if (evt.changedAttribute.toString() !== "aria-hidden") {
|
||||
if (evt.changedAttribute !== "aria-hidden") {
|
||||
// Only handle aria-hidden attribute change.
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -1745,7 +1745,7 @@ function objAttrChangedChecker(aID, aAttr) {
|
|||
return;
|
||||
}
|
||||
|
||||
is(event.changedAttribute.toString(), aAttr,
|
||||
is(event.changedAttribute, aAttr,
|
||||
"Wrong attribute name of the object attribute changed event.");
|
||||
};
|
||||
|
||||
|
@ -1754,7 +1754,7 @@ function objAttrChangedChecker(aID, aAttr) {
|
|||
var scEvent = aEvent.QueryInterface(
|
||||
nsIAccessibleObjectAttributeChangedEvent);
|
||||
return (aEvent.accessible == getAccessible(this.target)) &&
|
||||
(scEvent.changedAttribute.toString() == aAttr);
|
||||
(scEvent.changedAttribute == aAttr);
|
||||
}
|
||||
return false;
|
||||
};
|
||||
|
|
Загрузка…
Ссылка в новой задаче