Index: content/browser/compositor/gpu_process_transport_factory.cc |
diff --git a/content/browser/compositor/gpu_process_transport_factory.cc b/content/browser/compositor/gpu_process_transport_factory.cc |
index 713812a1012a9e7a75bde89fbb3c362a4d9426a0..c9023603115834b013cd5d95417162f244a19653 100644 |
--- a/content/browser/compositor/gpu_process_transport_factory.cc |
+++ b/content/browser/compositor/gpu_process_transport_factory.cc |
@@ -175,7 +175,10 @@ struct GpuProcessTransportFactory::PerCompositorData { |
}; |
GpuProcessTransportFactory::GpuProcessTransportFactory() |
- : task_graph_runner_(new cc::SingleThreadTaskGraphRunner), |
+ : frame_sink_id_allocator_( |
+ 0 /* client_id, not to conflict with the client_id |
boliu
2017/02/15 23:58:56
nit: 0u everwhere
Fady Samuel
2017/02/17 14:00:24
nit: Maybe add a constexpr at the top of the file
xlai (Olivia)
2017/02/17 15:55:11
Done.
xlai (Olivia)
2017/02/17 15:55:11
Done.
|
+ generated from RenderWidgetHostImpl */), |
+ task_graph_runner_(new cc::SingleThreadTaskGraphRunner), |
callback_factory_(this) { |
cc::SetClientNameForMetrics("Browser"); |
@@ -689,12 +692,7 @@ GpuProcessTransportFactory::GetContextFactoryPrivate() { |
} |
cc::FrameSinkId GpuProcessTransportFactory::AllocateFrameSinkId() { |
- // The FrameSinkId generated here must be unique with |
- // RenderWidgetHostViewAura's |
- // and RenderWidgetHostViewMac's FrameSinkId allocation. |
- // TODO(crbug.com/685777): Centralize allocation in one place for easier |
- // maintenance. |
- return cc::FrameSinkId(0, next_sink_id_++); |
+ return frame_sink_id_allocator_.NextFrameSinkId(); |
} |
void GpuProcessTransportFactory::SetDisplayVisible(ui::Compositor* compositor, |