Chromium Code Reviews| Index: content/browser/accessibility/browser_accessibility.h |
| diff --git a/content/browser/accessibility/browser_accessibility.h b/content/browser/accessibility/browser_accessibility.h |
| index 643e5950d5a485afbea2450a8fb6224ada79a7f6..27f6a74c8b2f0919b13b15aae19f6a4ed4cec720 100644 |
| --- a/content/browser/accessibility/browser_accessibility.h |
| +++ b/content/browser/accessibility/browser_accessibility.h |
| @@ -283,6 +283,12 @@ class CONTENT_EXPORT BrowserAccessibility { |
| // bounds offsets. |
| BrowserAccessibility* GetParentForBoundsCalculation() const; |
| + // If a bounding rectangle is empty, compute it based on the union of its |
| + // children, since most accessibility APIs don't like elements with no |
| + // bounds, but "virtual" elements in the accessibility tree that don't |
| + // correspond to a layed-out element sometimes don't have bounds. |
|
David Tseng
2015/06/22 21:29:36
What happens if there are multiple levels of empty
dmazzoni
2015/06/23 05:36:42
It calls GetLocalBoundsRect on each child, which c
David Tseng
2015/06/23 18:27:53
Ok got it; it's alternating recursively calling Fi
|
| + void FixEmptyBounds(gfx::Rect* bounds) const; |
| + |
| // Convert the bounding rectangle of an element (which is relative to |
| // its nearest scrollable ancestor) to local bounds (which are relative |
| // to the top of the web accessibility tree). |