OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_H_ | 5 #ifndef CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_H_ |
6 #define CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_H_ | 6 #define CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <utility> | 9 #include <utility> |
10 #include <vector> | 10 #include <vector> |
(...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
291 | 291 |
292 // Returns true if this node is an editable text field of any kind. | 292 // Returns true if this node is an editable text field of any kind. |
293 bool IsEditableText() const; | 293 bool IsEditableText() const; |
294 | 294 |
295 // True if this is a web area, and its grandparent is a presentational iframe. | 295 // True if this is a web area, and its grandparent is a presentational iframe. |
296 bool IsWebAreaForPresentationalIframe() const; | 296 bool IsWebAreaForPresentationalIframe() const; |
297 | 297 |
298 bool IsControl() const; | 298 bool IsControl() const; |
299 bool IsTextControl() const; | 299 bool IsTextControl() const; |
300 | 300 |
| 301 // If an object is focusable but has no accessible name, use this |
| 302 // to compute a name from its descendants. |
| 303 std::string ComputeAccessibleNameFromDescendants(); |
| 304 |
301 protected: | 305 protected: |
302 BrowserAccessibility(); | 306 BrowserAccessibility(); |
303 | 307 |
304 // The manager of this tree of accessibility objects. | 308 // The manager of this tree of accessibility objects. |
305 BrowserAccessibilityManager* manager_; | 309 BrowserAccessibilityManager* manager_; |
306 | 310 |
307 // The underlying node. | 311 // The underlying node. |
308 ui::AXNode* node_; | 312 ui::AXNode* node_; |
309 | 313 |
310 private: | 314 private: |
(...skipping 11 matching lines...) Expand all Loading... |
322 // its nearest scrollable ancestor) to local bounds (which are relative | 326 // its nearest scrollable ancestor) to local bounds (which are relative |
323 // to the top of the web accessibility tree). | 327 // to the top of the web accessibility tree). |
324 gfx::Rect ElementBoundsToLocalBounds(gfx::Rect bounds) const; | 328 gfx::Rect ElementBoundsToLocalBounds(gfx::Rect bounds) const; |
325 | 329 |
326 DISALLOW_COPY_AND_ASSIGN(BrowserAccessibility); | 330 DISALLOW_COPY_AND_ASSIGN(BrowserAccessibility); |
327 }; | 331 }; |
328 | 332 |
329 } // namespace content | 333 } // namespace content |
330 | 334 |
331 #endif // CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_H_ | 335 #endif // CONTENT_BROWSER_ACCESSIBILITY_BROWSER_ACCESSIBILITY_H_ |
OLD | NEW |