diff --git a/engine/src/flutter/shell/platform/darwin/ios/framework/Source/vsync_waiter_ios.mm b/engine/src/flutter/shell/platform/darwin/ios/framework/Source/vsync_waiter_ios.mm index b00b1cf864..cb4858d0f8 100644 --- a/engine/src/flutter/shell/platform/darwin/ios/framework/Source/vsync_waiter_ios.mm +++ b/engine/src/flutter/shell/platform/darwin/ios/framework/Source/vsync_waiter_ios.mm @@ -76,7 +76,14 @@ void VsyncWaiterIOS::AwaitVSync() { CFTimeInterval delay = CACurrentMediaTime() - link.timestamp; fml::TimePoint frame_start_time = fml::TimePoint::Now() - fml::TimeDelta::FromSecondsF(delay); - fml::TimePoint frame_target_time = frame_start_time + fml::TimeDelta::FromSecondsF(link.duration); + + CFTimeInterval duration; + if (@available(iOS 10.0, *)) { + duration = link.targetTimestamp - link.timestamp; + } else { + duration = link.duration; + } + fml::TimePoint frame_target_time = frame_start_time + fml::TimeDelta::FromSecondsF(duration); std::unique_ptr recorder = std::make_unique();