| Index: content/renderer/gpu/compositor_output_surface.cc
|
| diff --git a/content/renderer/gpu/compositor_output_surface.cc b/content/renderer/gpu/compositor_output_surface.cc
|
| index cc55ffa884adf3be780559afa7a34e574381b9f3..3e903b67489dab52f700a4c06ab7b4a73c79beac 100644
|
| --- a/content/renderer/gpu/compositor_output_surface.cc
|
| +++ b/content/renderer/gpu/compositor_output_surface.cc
|
| @@ -42,6 +42,7 @@ IPC::ForwardingMessageFilter* CompositorOutputSurface::CreateFilter(
|
| {
|
| uint32 messages_to_filter[] = {
|
| ViewMsg_UpdateVSyncParameters::ID,
|
| + ViewMsg_DidVSync::ID,
|
| ViewMsg_SwapCompositorFrameAck::ID
|
| };
|
|
|
| @@ -106,6 +107,7 @@ void CompositorOutputSurface::OnMessageReceived(const IPC::Message& message) {
|
| return;
|
| IPC_BEGIN_MESSAGE_MAP(CompositorOutputSurface, message)
|
| IPC_MESSAGE_HANDLER(ViewMsg_UpdateVSyncParameters, OnUpdateVSyncParameters);
|
| + IPC_MESSAGE_HANDLER(ViewMsg_DidVSync, DidVSync);
|
| IPC_MESSAGE_HANDLER(ViewMsg_SwapCompositorFrameAck, OnSwapAck);
|
| IPC_END_MESSAGE_MAP()
|
| }
|
| @@ -117,6 +119,18 @@ void CompositorOutputSurface::OnUpdateVSyncParameters(
|
| client_->OnVSyncParametersChanged(timebase, interval);
|
| }
|
|
|
| +void CompositorOutputSurface::EnableVSyncNotification(bool enable) {
|
| + DCHECK(CalledOnValidThread());
|
| + DCHECK(client_);
|
| + Send(new ViewHostMsg_EnableVSyncNotification(routing_id_, enable));
|
| +}
|
| +
|
| +void CompositorOutputSurface::DidVSync(base::TimeTicks frame_time) {
|
| + DCHECK(CalledOnValidThread());
|
| + DCHECK(client_);
|
| + client_->DidVSync(frame_time);
|
| +}
|
| +
|
| void CompositorOutputSurface::OnSwapAck(const cc::CompositorFrameAck& ack) {
|
| client_->OnSendFrameToParentCompositorAck(ack);
|
| }
|
|
|