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

Unified Diff: ui/views/view.cc

Issue 1124223010: ui: Eliminate allocating gfx::Canvas on the heap for every view. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: canvasstack: addTODO Created 5 years, 7 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 | « ui/native_theme/common_theme.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/view.cc
diff --git a/ui/views/view.cc b/ui/views/view.cc
index 6964cbf2f6dfc78a9d1600c4f1297f861708691a..6890603cbd4e29ef9a24f4f3ad318f2e8e9eba4e 100644
--- a/ui/views/view.cc
+++ b/ui/views/view.cc
@@ -806,6 +806,7 @@ void View::Paint(const ui::PaintContext& parent_context) {
if (is_invalidated || !paint_cache_.UseCache(context)) {
ui::PaintRecorder recorder(context, &paint_cache_);
gfx::Canvas* canvas = recorder.canvas();
+ // TODO(danakj): This is not needed with impl-side/slimming paint.
gfx::ScopedCanvas scoped_canvas(canvas);
// If the View we are about to paint requested the canvas to be flipped, we
« no previous file with comments | « ui/native_theme/common_theme.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698