| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2008, 2009, 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2008, 2009, 2011 Apple Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 368 return node->document().activeModalDialog(); | 368 return node->document().activeModalDialog(); |
| 369 } | 369 } |
| 370 | 370 |
| 371 } // namespace | 371 } // namespace |
| 372 | 372 |
| 373 AXObject::AXObject(AXObjectCacheImpl& axObjectCache) | 373 AXObject::AXObject(AXObjectCacheImpl& axObjectCache) |
| 374 : m_id(0) | 374 : m_id(0) |
| 375 , m_haveChildren(false) | 375 , m_haveChildren(false) |
| 376 , m_role(UnknownRole) | 376 , m_role(UnknownRole) |
| 377 , m_lastKnownIsIgnoredValue(DefaultBehavior) | 377 , m_lastKnownIsIgnoredValue(DefaultBehavior) |
| 378 , m_parent(0) | 378 , m_parent(nullptr) |
| 379 , m_lastModificationCount(-1) | 379 , m_lastModificationCount(-1) |
| 380 , m_cachedIsIgnored(false) | 380 , m_cachedIsIgnored(false) |
| 381 , m_cachedIsInertOrAriaHidden(false) | 381 , m_cachedIsInertOrAriaHidden(false) |
| 382 , m_cachedIsDescendantOfLeafNode(false) | 382 , m_cachedIsDescendantOfLeafNode(false) |
| 383 , m_cachedIsDescendantOfDisabledNode(false) | 383 , m_cachedIsDescendantOfDisabledNode(false) |
| 384 , m_cachedHasInheritedPresentationalRole(false) | 384 , m_cachedHasInheritedPresentationalRole(false) |
| 385 , m_cachedIsPresentationalChild(false) | 385 , m_cachedIsPresentationalChild(false) |
| 386 , m_cachedLiveRegionRoot(0) | 386 , m_cachedLiveRegionRoot(nullptr) |
| 387 , m_axObjectCache(&axObjectCache) | 387 , m_axObjectCache(&axObjectCache) |
| 388 { | 388 { |
| 389 } | 389 } |
| 390 | 390 |
| 391 AXObject::~AXObject() | 391 AXObject::~AXObject() |
| 392 { | 392 { |
| 393 ASSERT(isDetached()); | 393 ASSERT(isDetached()); |
| 394 } | 394 } |
| 395 | 395 |
| 396 void AXObject::detach() | 396 void AXObject::detach() |
| (...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 660 updateCachedAttributeValuesIfNeeded(); | 660 updateCachedAttributeValuesIfNeeded(); |
| 661 return m_cachedHasInheritedPresentationalRole; | 661 return m_cachedHasInheritedPresentationalRole; |
| 662 } | 662 } |
| 663 | 663 |
| 664 bool AXObject::isPresentationalChild() const | 664 bool AXObject::isPresentationalChild() const |
| 665 { | 665 { |
| 666 updateCachedAttributeValuesIfNeeded(); | 666 updateCachedAttributeValuesIfNeeded(); |
| 667 return m_cachedIsPresentationalChild; | 667 return m_cachedIsPresentationalChild; |
| 668 } | 668 } |
| 669 | 669 |
| 670 String AXObject::name(AXNameFrom& nameFrom, Vector<AXObject*>& nameObjects) | 670 String AXObject::name(AXNameFrom& nameFrom, WillBeHeapVector<RawPtrWillBeMember<
AXObject>>& nameObjects) |
| 671 { | 671 { |
| 672 HashSet<AXObject*> visited; | 672 WillBeHeapHashSet<RawPtrWillBeMember<AXObject>> visited; |
| 673 return textAlternative(false, false, visited, &nameFrom, &nameObjects); | 673 return textAlternative(false, false, visited, &nameFrom, &nameObjects); |
| 674 } | 674 } |
| 675 | 675 |
| 676 // In ARIA 1.1, the default value for aria-orientation changed from horizontal t
o undefined. | 676 // In ARIA 1.1, the default value for aria-orientation changed from horizontal t
o undefined. |
| 677 AccessibilityOrientation AXObject::orientation() const | 677 AccessibilityOrientation AXObject::orientation() const |
| 678 { | 678 { |
| 679 return AccessibilityOrientationUndefined; | 679 return AccessibilityOrientationUndefined; |
| 680 } | 680 } |
| 681 | 681 |
| 682 static String queryString(WebLocalizedString::Name name) | 682 static String queryString(WebLocalizedString::Name name) |
| (...skipping 790 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1473 return roleNameVector->at(role); | 1473 return roleNameVector->at(role); |
| 1474 } | 1474 } |
| 1475 | 1475 |
| 1476 const AtomicString& AXObject::internalRoleName(AccessibilityRole role) | 1476 const AtomicString& AXObject::internalRoleName(AccessibilityRole role) |
| 1477 { | 1477 { |
| 1478 static const Vector<AtomicString>* internalRoleNameVector = createInternalRo
leNameVector(); | 1478 static const Vector<AtomicString>* internalRoleNameVector = createInternalRo
leNameVector(); |
| 1479 | 1479 |
| 1480 return internalRoleNameVector->at(role); | 1480 return internalRoleNameVector->at(role); |
| 1481 } | 1481 } |
| 1482 | 1482 |
| 1483 DEFINE_TRACE(AXObject) |
| 1484 { |
| 1485 visitor->trace(m_children); |
| 1486 visitor->trace(m_parent); |
| 1487 visitor->trace(m_cachedLiveRegionRoot); |
| 1488 visitor->trace(m_axObjectCache); |
| 1489 } |
| 1490 |
| 1483 } // namespace blink | 1491 } // namespace blink |
| OLD | NEW |