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

Unified Diff: chrome/browser/ui/views/page_info/page_info_popup_view.cc

Issue 2758323002: Broke out layout metric information from ViewsDelegate to LayoutProvider (Closed)
Patch Set: Deleted LayoutDelegate and HarmonyLayoutDelegate. 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: chrome/browser/ui/views/page_info/page_info_popup_view.cc
diff --git a/chrome/browser/ui/views/page_info/page_info_popup_view.cc b/chrome/browser/ui/views/page_info/page_info_popup_view.cc
index c1b73ff459d28444d0364d5c46c54b595f4e59cf..f1618246020e76cd26395b5b9a4bd666395377df 100644
--- a/chrome/browser/ui/views/page_info/page_info_popup_view.cc
+++ b/chrome/browser/ui/views/page_info/page_info_popup_view.cc
@@ -24,7 +24,7 @@
#include "chrome/browser/ui/page_info/page_info.h"
#include "chrome/browser/ui/views/collected_cookies_views.h"
#include "chrome/browser/ui/views/harmony/chrome_typography.h"
-#include "chrome/browser/ui/views/harmony/layout_delegate.h"
+#include "chrome/browser/ui/views/harmony/chrome_views_layout_delegate.h"
#include "chrome/browser/ui/views/page_info/chosen_object_row.h"
#include "chrome/browser/ui/views/page_info/non_accessible_image_view.h"
#include "chrome/browser/ui/views/page_info/permission_selector_row.h"
@@ -308,7 +308,7 @@ InternalPageInfoPopupView::InternalPageInfoPopupView(
SetLayoutManager(new views::BoxLayout(views::BoxLayout::kHorizontal, kSpacing,
kSpacing, kSpacing));
set_margins(gfx::Insets());
- if (LayoutDelegate::Get()->ShouldShowWindowIcon()) {
+ if (ChromeViewsLayoutDelegate::Get()->ShouldShowWindowIcon()) {
views::ImageView* icon_view = new NonAccessibleImageView();
ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance();
icon_view->SetImage(rb.GetImageSkiaNamed(icon));
@@ -436,8 +436,8 @@ PageInfoPopupView::PageInfoPopupView(
// In non-material, titles are inset from the dialog margin. Ensure the
// horizontal insets match.
set_title_margins(
- gfx::Insets(LayoutDelegate::Get()->GetMetric(
- LayoutDelegate::Metric::PANEL_CONTENT_MARGIN),
+ gfx::Insets(ChromeViewsLayoutDelegate::Get()->GetDistanceMetric(
+ ChromeDistanceMetric::PANEL_CONTENT_MARGIN),
side_margin, 0, side_margin));
}
views::BubbleDialogDelegateView::CreateBubble(this);

Powered by Google App Engine
This is Rietveld 408576698