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 * Copyright (C) 2008 Nuanti Ltd. | 3 * Copyright (C) 2008 Nuanti Ltd. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * | 8 * |
9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
238 AccessibilityOrientationVertical, | 238 AccessibilityOrientationVertical, |
239 AccessibilityOrientationHorizontal, | 239 AccessibilityOrientationHorizontal, |
240 }; | 240 }; |
241 | 241 |
242 enum AXObjectInclusion { | 242 enum AXObjectInclusion { |
243 IncludeObject, | 243 IncludeObject, |
244 IgnoreObject, | 244 IgnoreObject, |
245 DefaultBehavior, | 245 DefaultBehavior, |
246 }; | 246 }; |
247 | 247 |
| 248 enum class AXSupportedAction { |
| 249 None = 0, |
| 250 Activate, |
| 251 Check, |
| 252 Click, |
| 253 Jump, |
| 254 Open, |
| 255 Press, |
| 256 Select, |
| 257 Uncheck |
| 258 }; |
| 259 |
248 enum AccessibilityButtonState { | 260 enum AccessibilityButtonState { |
249 ButtonStateOff = 0, | 261 ButtonStateOff = 0, |
250 ButtonStateOn, | 262 ButtonStateOn, |
251 ButtonStateMixed, | 263 ButtonStateMixed, |
252 }; | 264 }; |
253 | 265 |
254 enum AccessibilityTextDirection { | 266 enum AccessibilityTextDirection { |
255 AccessibilityTextDirectionLTR, | 267 AccessibilityTextDirectionLTR, |
256 AccessibilityTextDirectionRTL, | 268 AccessibilityTextDirectionRTL, |
257 AccessibilityTextDirectionTTB, | 269 AccessibilityTextDirectionTTB, |
(...skipping 530 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
788 virtual void markers(Vector<DocumentMarker::MarkerType>&, | 800 virtual void markers(Vector<DocumentMarker::MarkerType>&, |
789 Vector<AXRange>&) const {} | 801 Vector<AXRange>&) const {} |
790 // For an inline text box. | 802 // For an inline text box. |
791 // The integer horizontal pixel offset of each character in the string; | 803 // The integer horizontal pixel offset of each character in the string; |
792 // negative values for RTL. | 804 // negative values for RTL. |
793 virtual void textCharacterOffsets(Vector<int>&) const {} | 805 virtual void textCharacterOffsets(Vector<int>&) const {} |
794 // The start and end character offset of each word in the object's text. | 806 // The start and end character offset of each word in the object's text. |
795 virtual void wordBoundaries(Vector<AXRange>&) const {} | 807 virtual void wordBoundaries(Vector<AXRange>&) const {} |
796 | 808 |
797 // Properties of interactive elements. | 809 // Properties of interactive elements. |
798 String actionVerb() const; | 810 AXSupportedAction action() const; |
799 virtual AccessibilityButtonState checkboxOrRadioValue() const; | 811 virtual AccessibilityButtonState checkboxOrRadioValue() const; |
800 virtual AriaCurrentState ariaCurrentState() const { | 812 virtual AriaCurrentState ariaCurrentState() const { |
801 return AriaCurrentStateUndefined; | 813 return AriaCurrentStateUndefined; |
802 } | 814 } |
803 virtual InvalidState getInvalidState() const { return InvalidStateUndefined; } | 815 virtual InvalidState getInvalidState() const { return InvalidStateUndefined; } |
804 // Only used when invalidState() returns InvalidStateOther. | 816 // Only used when invalidState() returns InvalidStateOther. |
805 virtual String ariaInvalidValue() const { return String(); } | 817 virtual String ariaInvalidValue() const { return String(); } |
806 virtual String valueDescription() const { return String(); } | 818 virtual String valueDescription() const { return String(); } |
807 virtual float valueForRange() const { return 0.0f; } | 819 virtual float valueForRange() const { return 0.0f; } |
808 virtual float maxValueForRange() const { return 0.0f; } | 820 virtual float maxValueForRange() const { return 0.0f; } |
(...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1064 static unsigned s_numberOfLiveAXObjects; | 1076 static unsigned s_numberOfLiveAXObjects; |
1065 }; | 1077 }; |
1066 | 1078 |
1067 #define DEFINE_AX_OBJECT_TYPE_CASTS(thisType, predicate) \ | 1079 #define DEFINE_AX_OBJECT_TYPE_CASTS(thisType, predicate) \ |
1068 DEFINE_TYPE_CASTS(thisType, AXObject, object, object->predicate, \ | 1080 DEFINE_TYPE_CASTS(thisType, AXObject, object, object->predicate, \ |
1069 object.predicate) | 1081 object.predicate) |
1070 | 1082 |
1071 } // namespace blink | 1083 } // namespace blink |
1072 | 1084 |
1073 #endif // AXObject_h | 1085 #endif // AXObject_h |
OLD | NEW |