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

Unified Diff: cc/surfaces/surface_aggregator.h

Issue 1496103002: Reusing base::IdType<...> to implement SurfaceId. Base URL: https://chromium.googlesource.com/chromium/src.git@type-safe-id-base
Patch Set: Rebasing + dusting off... Created 4 years, 10 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/surfaces/display_unittest.cc ('k') | cc/surfaces/surface_aggregator_perftest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/surfaces/surface_aggregator.h
diff --git a/cc/surfaces/surface_aggregator.h b/cc/surfaces/surface_aggregator.h
index b5a7fb938ff1bc143c084d6409f999b995c79cf7..741d83c13d5cbf8589e20a46964e06f74bde26bc 100644
--- a/cc/surfaces/surface_aggregator.h
+++ b/cc/surfaces/surface_aggregator.h
@@ -36,7 +36,7 @@ class CC_SURFACES_EXPORT SurfaceAggregatorClient {
class CC_SURFACES_EXPORT SurfaceAggregator {
public:
- using SurfaceIndexMap = std::unordered_map<SurfaceId, int, SurfaceIdHash>;
+ using SurfaceIndexMap = std::unordered_map<SurfaceId, int, SurfaceId::Hasher>;
SurfaceAggregator(SurfaceAggregatorClient* client,
SurfaceManager* manager,
@@ -116,13 +116,13 @@ class CC_SURFACES_EXPORT SurfaceAggregator {
using RenderPassIdAllocatorMap =
std::unordered_map<SurfaceId,
scoped_ptr<RenderPassIdAllocator>,
- SurfaceIdHash>;
+ SurfaceId::Hasher>;
RenderPassIdAllocatorMap render_pass_allocator_map_;
int next_render_pass_id_;
const bool aggregate_only_damaged_;
using SurfaceToResourceChildIdMap =
- std::unordered_map<SurfaceId, int, SurfaceIdHash>;
+ std::unordered_map<SurfaceId, int, SurfaceId::Hasher>;
SurfaceToResourceChildIdMap surface_id_to_resource_child_id_;
// The following state is only valid for the duration of one Aggregate call
@@ -140,7 +140,7 @@ class CC_SURFACES_EXPORT SurfaceAggregator {
SurfaceIndexMap contained_surfaces_;
// After surface validation, every Surface in this set is valid.
- std::unordered_set<SurfaceId, SurfaceIdHash> valid_surfaces_;
+ std::unordered_set<SurfaceId, SurfaceId::Hasher> valid_surfaces_;
// This is the pass list for the aggregated frame.
RenderPassList* dest_pass_list_;
« no previous file with comments | « cc/surfaces/display_unittest.cc ('k') | cc/surfaces/surface_aggregator_perftest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698