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

Unified Diff: cc/test/test_shared_bitmap_manager.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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/test/test_layer_tree_host_base.cc ('k') | cc/tiles/eviction_tile_priority_queue.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/test_shared_bitmap_manager.cc
diff --git a/cc/test/test_shared_bitmap_manager.cc b/cc/test/test_shared_bitmap_manager.cc
index 922c2f34adf323317763958712e01a3be1defa97..604f669af5bbb643ef9aa3a94cf17182e62eed36 100644
--- a/cc/test/test_shared_bitmap_manager.cc
+++ b/cc/test/test_shared_bitmap_manager.cc
@@ -38,7 +38,7 @@ std::unique_ptr<SharedBitmap> TestSharedBitmapManager::AllocateSharedBitmap(
memory->CreateAndMapAnonymous(size.GetArea() * 4);
SharedBitmapId id = SharedBitmap::GenerateId();
bitmap_map_[id] = memory.get();
- return base::WrapUnique(new OwnedSharedBitmap(std::move(memory), id));
+ return base::MakeUnique<OwnedSharedBitmap>(std::move(memory), id);
}
std::unique_ptr<SharedBitmap> TestSharedBitmapManager::GetSharedBitmapFromId(
@@ -48,7 +48,7 @@ std::unique_ptr<SharedBitmap> TestSharedBitmapManager::GetSharedBitmapFromId(
if (bitmap_map_.find(id) == bitmap_map_.end())
return nullptr;
uint8_t* pixels = static_cast<uint8_t*>(bitmap_map_[id]->memory());
- return base::WrapUnique(new SharedBitmap(pixels, id));
+ return base::MakeUnique<SharedBitmap>(pixels, id);
}
} // namespace cc
« no previous file with comments | « cc/test/test_layer_tree_host_base.cc ('k') | cc/tiles/eviction_tile_priority_queue.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698