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

Side by Side Diff: cc/test/fake_image_serialization_processor.cc

Issue 2258833002: Re-write many calls to WrapUnique() with MakeUnique() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 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 unified diff | Download patch
« no previous file with comments | « cc/raster/staging_buffer_pool.cc ('k') | cc/test/fake_painted_scrollbar_layer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "cc/test/fake_image_serialization_processor.h" 5 #include "cc/test/fake_image_serialization_processor.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/memory/ptr_util.h" 8 #include "base/memory/ptr_util.h"
9 #include "cc/test/fake_client_picture_cache.h" 9 #include "cc/test/fake_client_picture_cache.h"
10 #include "cc/test/fake_engine_picture_cache.h" 10 #include "cc/test/fake_engine_picture_cache.h"
11 #include "cc/test/picture_cache_model.h" 11 #include "cc/test/picture_cache_model.h"
12 12
13 namespace cc { 13 namespace cc {
14 14
15 FakeImageSerializationProcessor::FakeImageSerializationProcessor() 15 FakeImageSerializationProcessor::FakeImageSerializationProcessor()
16 : picture_cache_model_(base::WrapUnique(new PictureCacheModel)) {} 16 : picture_cache_model_(base::WrapUnique(new PictureCacheModel)) {}
17 17
18 FakeImageSerializationProcessor::~FakeImageSerializationProcessor() {} 18 FakeImageSerializationProcessor::~FakeImageSerializationProcessor() {}
19 19
20 std::unique_ptr<EnginePictureCache> 20 std::unique_ptr<EnginePictureCache>
21 FakeImageSerializationProcessor::CreateEnginePictureCache() { 21 FakeImageSerializationProcessor::CreateEnginePictureCache() {
22 return base::WrapUnique( 22 return base::MakeUnique<FakeEnginePictureCache>(picture_cache_model_.get());
23 new FakeEnginePictureCache(picture_cache_model_.get()));
24 } 23 }
25 24
26 std::unique_ptr<ClientPictureCache> 25 std::unique_ptr<ClientPictureCache>
27 FakeImageSerializationProcessor::CreateClientPictureCache() { 26 FakeImageSerializationProcessor::CreateClientPictureCache() {
28 return base::WrapUnique( 27 return base::MakeUnique<FakeClientPictureCache>(picture_cache_model_.get());
29 new FakeClientPictureCache(picture_cache_model_.get()));
30 } 28 }
31 29
32 } // namespace cc 30 } // namespace cc
OLDNEW
« no previous file with comments | « cc/raster/staging_buffer_pool.cc ('k') | cc/test/fake_painted_scrollbar_layer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698