Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(440)

Unified Diff: ui/accessibility/platform/ax_platform_node_base.cc

Issue 2795543002: Add GetScreenBoundsRect to ui::AXPlatformNodeDelegate (Closed)
Patch Set: Remove GetGlobalCoordinateOffset Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/accessibility/platform/ax_platform_node_base.cc
diff --git a/ui/accessibility/platform/ax_platform_node_base.cc b/ui/accessibility/platform/ax_platform_node_base.cc
index b72f5e8e64a57102769b41e5588044729e2ac6ac..4eaec9bd1f3c0d0a0a1f09f7af61a7a740cf0470 100644
--- a/ui/accessibility/platform/ax_platform_node_base.cc
+++ b/ui/accessibility/platform/ax_platform_node_base.cc
@@ -24,7 +24,8 @@ const AXNodeData& AXPlatformNodeBase::GetData() const {
gfx::Rect AXPlatformNodeBase::GetBoundsInScreen() const {
CHECK(delegate_);
gfx::Rect bounds = gfx::ToEnclosingRect(GetData().location);
- bounds.Offset(delegate_->GetGlobalCoordinateOffset());
+ gfx::Rect screen_bounds = delegate_->GetScreenBoundsRect();
+ bounds.Offset(screen_bounds.x(), screen_bounds.y());
dmazzoni 2017/04/04 15:05:19 I don't think this should be here. It should just
return bounds;
}

Powered by Google App Engine
This is Rietveld 408576698