Chromium Code Reviews| Index: chrome/browser/accessibility/accessibility_events.h |
| diff --git a/chrome/browser/accessibility/accessibility_events.h b/chrome/browser/accessibility/accessibility_events.h |
| index 28587fb6046fd6e88397993646b28b86e222e5d7..14b4f6fda692515db8835374962eb89246ef8bad 100644 |
| --- a/chrome/browser/accessibility/accessibility_events.h |
| +++ b/chrome/browser/accessibility/accessibility_events.h |
| @@ -225,6 +225,7 @@ class AccessibilityComboBoxInfo : public AccessibilityControlInfo { |
| int item_count_; |
| }; |
| + |
| // Accessibility information about a text box, passed to onControlFocused, |
| // onControlAction, and onTextChanged event listeners. |
| class AccessibilityTextBoxInfo : public AccessibilityControlInfo { |
| @@ -325,6 +326,52 @@ class AccessibilityMenuItemInfo : public AccessibilityControlInfo { |
| int item_count_; |
| }; |
| +// Accessibility information about a tree; this class is used by |
| +// onControlFocused event listeners. |
| +class AccessibilityTreeInfo : public AccessibilityControlInfo { |
| + public: |
| + AccessibilityTreeInfo(Profile* profile, const std::string& menu_name); |
| + |
| + virtual const char* type() const OVERRIDE; |
| +}; |
| + |
| +// Accessibility information about a tree item; this class is used by |
| +// onControlFocused event listeners. |
| +class AccessibilityTreeItemInfo : public AccessibilityControlInfo { |
| + public: |
| + AccessibilityTreeItemInfo(Profile* profile, |
| + const std::string& name, |
| + const std::string& context, |
| + int item_depth, |
| + int item_index, |
| + int item_count, |
| + int children_count, |
| + bool is_expanded); |
| + |
| + virtual const char* type() const OVERRIDE; |
| + |
| + virtual void SerializeToDict(base::DictionaryValue* dict) const OVERRIDE; |
| + |
| + int item_depth() const { return item_depth_; } |
| + int item_index() const { return item_index_; } |
| + int item_count() const { return item_count_; } |
| + int children_count() const { return children_count_; } |
| + bool is_expanded() const { return is_expanded_; } |
| + |
| + private: |
| + // 0-based item depth. |
| + int item_depth_; |
| + // The 0-based index of the current item and the number of total items at the |
| + // current depth. |
| + int item_index_; |
| + // Count of items at the current depth. |
| + int item_count_; |
| + // Count of items at the current depth. |
|
dmazzoni
2013/11/22 23:45:30
Should this be "Count of children..."?
zel
2013/11/23 00:17:16
Done.
|
| + int children_count_; |
| + // True if the node is expanded. |
| + bool is_expanded_; |
| +}; |
| + |
| // Accessibility information about a slider passed to onControlFocused |
| // and onControlAction event listeners. |
| class AccessibilitySliderInfo : public AccessibilityControlInfo { |