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

Unified Diff: chrome/browser/ui/views/omnibox/omnibox_popup_contents_view.cc

Issue 2877483003: Implements core logic for Pixel Canvas (Closed)
Patch Set: Sync with ToT Created 3 years, 4 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/omnibox/omnibox_popup_contents_view.cc
diff --git a/chrome/browser/ui/views/omnibox/omnibox_popup_contents_view.cc b/chrome/browser/ui/views/omnibox/omnibox_popup_contents_view.cc
index 8717a87f76aba9d24e438068c59df56be916cf27..22f4cfbd986c929703e316a188b16b8b9526681d 100644
--- a/chrome/browser/ui/views/omnibox/omnibox_popup_contents_view.cc
+++ b/chrome/browser/ui/views/omnibox/omnibox_popup_contents_view.cc
@@ -494,9 +494,10 @@ void OmniboxPopupContentsView::OnPaint(gfx::Canvas* canvas) {
g_bottom_shadow.Get().height());
}
-void OmniboxPopupContentsView::PaintChildren(const ui::PaintContext& context) {
+void OmniboxPopupContentsView::PaintChildren(
+ const views::PaintInfo& paint_info) {
if (base::FeatureList::IsEnabled(omnibox::kUIExperimentNarrowDropdown)) {
- View::PaintChildren(context);
+ View::PaintChildren(paint_info);
return;
}
@@ -504,15 +505,15 @@ void OmniboxPopupContentsView::PaintChildren(const ui::PaintContext& context) {
contents_bounds.Inset(0, g_top_shadow.Get().height(), 0,
g_bottom_shadow.Get().height());
- ui::ClipRecorder clip_recorder(context);
+ ui::ClipRecorder clip_recorder(paint_info.context());
clip_recorder.ClipRect(contents_bounds);
{
- ui::PaintRecorder recorder(context, size());
+ ui::PaintRecorder recorder(paint_info.context(), size());
SkColor background_color = result_view_at(0)->GetColor(
OmniboxResultView::NORMAL, OmniboxResultView::BACKGROUND);
recorder.canvas()->DrawColor(background_color);
}
- View::PaintChildren(context);
+ View::PaintChildren(paint_info);
}
////////////////////////////////////////////////////////////////////////////////

Powered by Google App Engine
This is Rietveld 408576698