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

Unified Diff: ui/compositor/paint_cache.cc

Issue 1494223003: cc: Shrink size of display item (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix some compilation issues in ui oops Created 5 years 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/compositor/paint_cache.h ('k') | ui/compositor/paint_recorder.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/compositor/paint_cache.cc
diff --git a/ui/compositor/paint_cache.cc b/ui/compositor/paint_cache.cc
index e9de88d188b4f6ec1c387cfc8f113a0a29c9cc82..ba3855ad307fac2b1edcac03ea986b6cad4e36c7 100644
--- a/ui/compositor/paint_cache.cc
+++ b/ui/compositor/paint_cache.cc
@@ -21,14 +21,13 @@ bool PaintCache::UseCache(const PaintContext& context,
return false;
DCHECK(context.list_);
gfx::Rect bounds_in_layer = context.ToLayerSpaceBounds(size_in_context);
- auto* item = context.list_->CreateAndAppendItem<cc::DrawingDisplayItem>(
- bounds_in_layer);
- display_item_.CloneTo(item);
+ context.list_->CreateAndAppendItem<cc::DrawingDisplayItem>(bounds_in_layer,
+ display_item_);
return true;
}
-void PaintCache::SetCache(const cc::DrawingDisplayItem* item) {
- item->CloneTo(&display_item_);
+void PaintCache::SetCache(const cc::DrawingDisplayItem& item) {
+ item.CloneTo(&display_item_);
has_cache_ = true;
}
« no previous file with comments | « ui/compositor/paint_cache.h ('k') | ui/compositor/paint_recorder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698