Changeset 53384 in webkit
- Timestamp:
- Jan 17, 2010 6:47:00 PM (14 years ago)
- Location:
- trunk/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebCore/ChangeLog
r53373 r53384 1 2010-01-17 Maciej Stachowiak <mjs@apple.com> 2 3 Reviewed by Dan Bernstein. 4 5 Avoid slow access to AX objects on attribute access when AX is off 6 https://bugs.webkit.org/show_bug.cgi?id=33779 7 8 ~4% Dromaeo attributes test speedup 9 10 * dom/Element.cpp: 11 (WebCore::Element::updateAfterAttributeChanged): Don't do expensive lookup of 12 AX object cache unless accessibility is on and an AX-related attribute is 13 changed. 14 1 15 2010-01-17 Kevin Watters <kevinwatters@gmail.com> 2 16 -
trunk/WebCore/dom/Element.cpp
r53363 r53384 594 594 void Element::updateAfterAttributeChanged(Attribute* attr) 595 595 { 596 AXObjectCache* axObjectCache = document()->axObjectCache(); 597 if (!axObjectCache->accessibilityEnabled()) 596 if (!AXObjectCache::accessibilityEnabled()) 598 597 return; 599 598 … … 601 600 if (attrName == aria_activedescendantAttr) { 602 601 // any change to aria-activedescendant attribute triggers accessibility focus change, but document focus remains intact 603 axObjectCache->handleActiveDescendantChanged(renderer());602 document()->axObjectCache()->handleActiveDescendantChanged(renderer()); 604 603 } else if (attrName == roleAttr) { 605 604 // the role attribute can change at any time, and the AccessibilityObject must pick up these changes 606 axObjectCache->handleAriaRoleChanged(renderer());605 document()->axObjectCache()->handleAriaRoleChanged(renderer()); 607 606 } else if (attrName == aria_valuenowAttr) { 608 607 // If the valuenow attribute changes, AX clients need to be notified. 609 axObjectCache->postNotification(renderer(), AXObjectCache::AXValueChanged, true);608 document()->axObjectCache()->postNotification(renderer(), AXObjectCache::AXValueChanged, true); 610 609 } else if (attrName == aria_labelAttr || attrName == aria_labeledbyAttr || attrName == altAttr || attrName == titleAttr) { 611 610 // If the content of an element changes due to an attribute change, notify accessibility. 612 axObjectCache->contentChanged(renderer());611 document()->axObjectCache()->contentChanged(renderer()); 613 612 } 614 613 }
Note: See TracChangeset
for help on using the changeset viewer.