| Index: ui/ozone/platform/drm/gpu/drm_vsync_provider.cc
|
| diff --git a/ui/ozone/platform/drm/gpu/drm_vsync_provider.cc b/ui/ozone/platform/drm/gpu/drm_vsync_provider.cc
|
| index 6c0e1ca0964b12c6726c016fe4d34d48877cff9e..a187da5f0d7dfbb561406bc731680264be1ecd0e 100644
|
| --- a/ui/ozone/platform/drm/gpu/drm_vsync_provider.cc
|
| +++ b/ui/ozone/platform/drm/gpu/drm_vsync_provider.cc
|
| @@ -4,10 +4,7 @@
|
|
|
| #include "ui/ozone/platform/drm/gpu/drm_vsync_provider.h"
|
|
|
| -#include "base/time/time.h"
|
| -#include "ui/ozone/platform/drm/gpu/crtc_controller.h"
|
| #include "ui/ozone/platform/drm/gpu/drm_window.h"
|
| -#include "ui/ozone/platform/drm/gpu/hardware_display_controller.h"
|
|
|
| namespace ui {
|
|
|
| @@ -18,25 +15,7 @@ DrmVSyncProvider::~DrmVSyncProvider() {
|
| }
|
|
|
| void DrmVSyncProvider::GetVSyncParameters(const UpdateVSyncCallback& callback) {
|
| - HardwareDisplayController* controller = window_->GetController();
|
| - if (!controller)
|
| - return;
|
| -
|
| - // If we're in mirror mode the 2 CRTCs should have similar modes with the same
|
| - // refresh rates.
|
| - CrtcController* crtc = controller->crtc_controllers()[0];
|
| - // The value is invalid, so we can't update the parameters.
|
| - if (controller->GetTimeOfLastFlip() == 0 || crtc->mode().vrefresh == 0)
|
| - return;
|
| -
|
| - // Stores the time of the last refresh.
|
| - base::TimeTicks timebase =
|
| - base::TimeTicks::FromInternalValue(controller->GetTimeOfLastFlip());
|
| - // Stores the refresh rate.
|
| - base::TimeDelta interval =
|
| - base::TimeDelta::FromSeconds(1) / crtc->mode().vrefresh;
|
| -
|
| - callback.Run(timebase, interval);
|
| + window_->GetVSyncParameters(callback);
|
| }
|
|
|
| } // namespace ui
|
|
|