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 1968 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1979 case kNoneRole: | 1979 case kNoneRole: |
1980 case kParagraphRole: | 1980 case kParagraphRole: |
1981 case kPreRole: | 1981 case kPreRole: |
1982 case kPresentationalRole: | 1982 case kPresentationalRole: |
1983 // Spec says we should always expose the name on rows, | 1983 // Spec says we should always expose the name on rows, |
1984 // but for performance reasons we only do it | 1984 // but for performance reasons we only do it |
1985 // if the row might receive focus | 1985 // if the row might receive focus |
1986 case kRowRole: | 1986 case kRowRole: |
1987 case kRubyRole: | 1987 case kRubyRole: |
1988 case kRulerRole: | 1988 case kRulerRole: |
| 1989 result = recursive || (CanReceiveAccessibilityFocus() && !IsEditable()); |
| 1990 break; |
| 1991 |
1989 case kUnknownRole: | 1992 case kUnknownRole: |
1990 case kNumRoles: | 1993 case kNumRoles: |
1991 result = recursive || (CanReceiveAccessibilityFocus() && !IsEditable()); | 1994 LOG(ERROR) << "kUnknownRole for " << GetNode(); |
| 1995 NOTREACHED(); |
1992 break; | 1996 break; |
1993 } | 1997 } |
1994 | 1998 |
1995 return result; | 1999 return result; |
1996 } | 2000 } |
1997 | 2001 |
1998 AccessibilityRole AXObjectImpl::ButtonRoleType() const { | 2002 AccessibilityRole AXObjectImpl::ButtonRoleType() const { |
1999 // If aria-pressed is present, then it should be exposed as a toggle button. | 2003 // If aria-pressed is present, then it should be exposed as a toggle button. |
2000 // http://www.w3.org/TR/wai-aria/states_and_properties#aria-pressed | 2004 // http://www.w3.org/TR/wai-aria/states_and_properties#aria-pressed |
2001 if (AriaPressedIsPresent()) | 2005 if (AriaPressedIsPresent()) |
(...skipping 20 matching lines...) Expand all Loading... |
2022 } | 2026 } |
2023 | 2027 |
2024 DEFINE_TRACE(AXObjectImpl) { | 2028 DEFINE_TRACE(AXObjectImpl) { |
2025 visitor->Trace(children_); | 2029 visitor->Trace(children_); |
2026 visitor->Trace(parent_); | 2030 visitor->Trace(parent_); |
2027 visitor->Trace(cached_live_region_root_); | 2031 visitor->Trace(cached_live_region_root_); |
2028 visitor->Trace(ax_object_cache_); | 2032 visitor->Trace(ax_object_cache_); |
2029 } | 2033 } |
2030 | 2034 |
2031 } // namespace blink | 2035 } // namespace blink |
OLD | NEW |