| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #if defined(ENABLE_GPU) | 5 #if defined(ENABLE_GPU) |
| 6 | 6 |
| 7 #include "content/common/gpu/image_transport_surface.h" | 7 #include "content/common/gpu/image_transport_surface.h" |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
| (...skipping 335 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 346 } | 346 } |
| 347 } | 347 } |
| 348 | 348 |
| 349 gfx::Size PassThroughImageTransportSurface::GetSize() { | 349 gfx::Size PassThroughImageTransportSurface::GetSize() { |
| 350 return GLSurfaceAdapter::GetSize(); | 350 return GLSurfaceAdapter::GetSize(); |
| 351 } | 351 } |
| 352 | 352 |
| 353 PassThroughImageTransportSurface::~PassThroughImageTransportSurface() {} | 353 PassThroughImageTransportSurface::~PassThroughImageTransportSurface() {} |
| 354 | 354 |
| 355 void PassThroughImageTransportSurface::SendVSyncUpdateIfAvailable() { | 355 void PassThroughImageTransportSurface::SendVSyncUpdateIfAvailable() { |
| 356 base::TimeTicks timebase; | 356 GetVSyncParameters( |
| 357 base::TimeDelta interval; | 357 base::Bind(&ImageTransportHelper::SendUpdateVSyncParameters, |
| 358 if (GetVSyncParameters(&timebase, &interval)) { | 358 helper_->AsWeakPtr())); |
| 359 helper_->SendUpdateVSyncParameters(timebase, interval); | |
| 360 } | |
| 361 } | 359 } |
| 362 | 360 |
| 363 } // namespace content | 361 } // namespace content |
| 364 | 362 |
| 365 #endif // defined(ENABLE_GPU) | 363 #endif // defined(ENABLE_GPU) |
| OLD | NEW |