Ejemplo n.º 1
0
bool AXObject::accessibilityIsIgnored() const
{
    AXObjectCache* cache = axObjectCache();
    if (!cache)
        return true;

    AXComputedObjectAttributeCache* attributeCache = cache->computedObjectAttributeCache();
    if (attributeCache) {
        AXObjectInclusion ignored = attributeCache->getIgnored(axObjectID());
        switch (ignored) {
        case IgnoreObject:
            return true;
        case IncludeObject:
            return false;
        case DefaultBehavior:
            break;
        }
    }

    bool result = computeAccessibilityIsIgnored();

    if (attributeCache)
        attributeCache->setIgnored(axObjectID(), result ? IgnoreObject : IncludeObject);

    return result;
}