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

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

Issue 1724333002: [MD] Don't allow overflowing location icons to appear on top of toolbar (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/location_bar/location_bar_view.cc
diff --git a/chrome/browser/ui/views/location_bar/location_bar_view.cc b/chrome/browser/ui/views/location_bar/location_bar_view.cc
index 7adaf3fb21df88758a56c51d7105faf07dcd19cf..54d17bed84f24be3c9667050ba78fce82f4f8272 100644
--- a/chrome/browser/ui/views/location_bar/location_bar_view.cc
+++ b/chrome/browser/ui/views/location_bar/location_bar_view.cc
@@ -179,7 +179,12 @@ void LocationBarView::Init() {
// not prepared for that.
DCHECK(GetWidget());
- if (!ui::MaterialDesignController::IsModeMaterial()) {
+ if (ui::MaterialDesignController::IsModeMaterial()) {
+ // Make sure children with layers are clipped.
+ SetPaintToLayer(true);
bruthig 2016/02/24 17:02:58 Calling SetPaintToLayer(true) causes the View to c
Evan Stade 2016/02/24 23:14:17 done. (Only two spots use this technique AFAIK ---
+ SetFillsBoundsOpaquely(false);
+ layer()->SetMasksToBounds(true);
+ } else {
Peter Kasting 2016/02/24 01:46:08 Nit: Can combine this else with subsequent if and
Evan Stade 2016/02/24 23:14:18 Done.
if (is_popup_mode_) {
const int kOmniboxPopupBorderImages[] =
IMAGE_GRID(IDR_OMNIBOX_POPUP_BORDER_AND_SHADOW);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698