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

Unified Diff: chrome/browser/ui/views/page_info_bubble_view.cc

Issue 8863009: Fix alignment of avatar bubbles in the NTP (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: use Rect::Ofset() Created 9 years 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: chrome/browser/ui/views/page_info_bubble_view.cc
diff --git a/chrome/browser/ui/views/page_info_bubble_view.cc b/chrome/browser/ui/views/page_info_bubble_view.cc
index 6cc5cb7ab47e889915e8e6b4762235ad7b82b059..88a65081cbec821a59b1dd402094728a97b23b71 100644
--- a/chrome/browser/ui/views/page_info_bubble_view.cc
+++ b/chrome/browser/ui/views/page_info_bubble_view.cc
@@ -298,10 +298,12 @@ void PageInfoBubbleView::OnPageInfoModelChanged() {
#endif
}
-gfx::Point PageInfoBubbleView::GetAnchorPoint() {
+gfx::Rect PageInfoBubbleView::GetAnchorRect() {
// Compensate for some built-in padding in the icon.
- gfx::Point anchor(BubbleDelegateView::GetAnchorPoint());
- return anchor_view() ? anchor.Subtract(gfx::Point(0, 5)) : anchor;
+ gfx::Rect anchor(BubbleDelegateView::GetAnchorRect());
+ if (anchor_view())
+ anchor.Offset(0, -5);
msw 2011/12/08 00:40:14 Please change this to rect.Inset(5, 5); Thanks!
+ return anchor;
}
void PageInfoBubbleView::LinkClicked(views::Link* source, int event_flags) {

Powered by Google App Engine
This is Rietveld 408576698