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

Unified Diff: chrome/browser/ui/views/location_bar/location_bar_view.h

Issue 2348853004: Remove non-md code in location bar (Views). (Closed)
Patch Set: resolve change collision Created 4 years, 3 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/location_bar/location_bar_view.h
diff --git a/chrome/browser/ui/views/location_bar/location_bar_view.h b/chrome/browser/ui/views/location_bar/location_bar_view.h
index dc24665dc2823a10f6935b0c49ed17200f30b6b8..b20c54f74a5ad531ffffc264dcd3d527e6b9d284 100644
--- a/chrome/browser/ui/views/location_bar/location_bar_view.h
+++ b/chrome/browser/ui/views/location_bar/location_bar_view.h
@@ -112,6 +112,9 @@ class LocationBarView : public LocationBar,
SECURITY_CHIP_TEXT,
};
+ // Width (and height) of icons in location bar.
+ static constexpr int kLocationBarIconWidth = 16;
+
// The location bar view's class name.
static const char kViewClassName[];
@@ -123,8 +126,8 @@ class LocationBarView : public LocationBar,
~LocationBarView() override;
- // Returns the color for the location bar border in MD windows and non-MD
- // popup windows, given the window's |incognito| state.
+ // Returns the color for the location bar border given the window's
+ // |incognito| state.
static SkColor GetBorderColor(bool incognito);
// Initializes the LocationBarView.
@@ -186,9 +189,6 @@ class LocationBarView : public LocationBar,
// not where the icons are shown).
gfx::Point GetOmniboxViewOrigin() const;
- // Returns the width of the location icon.
- int GetLocationIconWidth() const;
-
// Shows |text| as an inline autocompletion. This is useful for IMEs, where
// we can't show the autocompletion inside the actual OmniboxView. See
// comments on |ime_inline_autocomplete_view_|.
@@ -275,7 +275,7 @@ class LocationBarView : public LocationBar,
// Returns the total amount of space reserved above or below the content,
// which is the vertical edge thickness plus the padding next to it.
- int GetVerticalEdgeThicknessWithPadding() const;
+ int GetTotalVerticalPadding() const;
// Updates |location_icon_view_| based on the current state and theme.
void RefreshLocationIcon();
@@ -371,7 +371,6 @@ class LocationBarView : public LocationBar,
void OnBoundsChanged(const gfx::Rect& previous_bounds) override;
void OnFocus() override;
void OnPaint(gfx::Canvas* canvas) override;
- void PaintChildren(const ui::PaintContext& context) override;
// views::DragController:
void WriteDragDataForView(View* sender,
@@ -406,9 +405,6 @@ class LocationBarView : public LocationBar,
// Our delegate.
Delegate* delegate_;
- // Object used to paint the border. Not used for material design.
- std::unique_ptr<views::Painter> border_painter_;
-
// An icon to the left of the edit field: the HTTPS lock, blank page icon,
// search icon, EV HTTPS bubble, etc.
LocationIconView* location_icon_view_;

Powered by Google App Engine
This is Rietveld 408576698