Flutter Engine
flutter::VsyncWaiterIOS Class Referencefinal

#import <vsync_waiter_ios.h>

Inheritance diagram for flutter::VsyncWaiterIOS:
flutter::VsyncWaiter

Instance Methods

() - VsyncWaiterIOS
 
() - ~VsyncWaiterIOS
 
- Instance Methods inherited from flutter::VsyncWaiter
virtual ~VsyncWaiter ()
 
void AsyncWaitForVsync (const Callback &callback)
 
void ScheduleSecondaryCallback (uintptr_t id, const fml::closure &callback)
 

Additional Inherited Members

- Public Types inherited from flutter::VsyncWaiter
using Callback = std::function< void(std::unique_ptr< FrameTimingsRecorder >)>
 
- Protected Member Functions inherited from flutter::VsyncWaiter
 VsyncWaiter (TaskRunners task_runners)
 
virtual void AwaitVSyncForSecondaryCallback ()
 
void FireCallback (fml::TimePoint frame_start_time, fml::TimePoint frame_target_time, bool pause_secondary_tasks=true)
 
- Protected Attributes inherited from flutter::VsyncWaiter
const TaskRunners task_runners_
 

Detailed Description

Definition at line 41 of file vsync_waiter_ios.h.

Constructor & Destructor Documentation

◆ VsyncWaiterIOS()

- VsyncWaiterIOS: (flutter::TaskRunners task_runners

Definition at line 20 of file vsync_waiter_ios.mm.

References callback, flutter::VsyncWaiter::FireCallback(), flutter::TaskRunners::GetUITaskRunner(), and flutter::VsyncWaiter::task_runners_.

21  : VsyncWaiter(std::move(task_runners)) {
22  auto callback = [this](std::unique_ptr<flutter::FrameTimingsRecorder> recorder) {
23  const fml::TimePoint start_time = recorder->GetVsyncStartTime();
24  const fml::TimePoint target_time = recorder->GetVsyncTargetTime();
25  FireCallback(start_time, target_time, true);
26  };
27  client_ =
28  fml::scoped_nsobject{[[VSyncClient alloc] initWithTaskRunner:task_runners_.GetUITaskRunner()
29  callback:callback]};
30 }
VsyncWaiter(TaskRunners task_runners)
Definition: vsync_waiter.cc:37
void FireCallback(fml::TimePoint frame_start_time, fml::TimePoint frame_target_time, bool pause_secondary_tasks=true)
Definition: vsync_waiter.cc:97
FlKeyEvent FlKeyResponderAsyncCallback callback

◆ ~VsyncWaiterIOS()

- VsyncWaiterIOS:

Definition at line 32 of file vsync_waiter_ios.mm.

References fml::scoped_nsprotocol< NST >::get().

32  {
33  // This way, we will get no more callbacks from the display link that holds a weak (non-nilling)
34  // reference to this C++ object.
35  [client_.get() invalidate];
36 }

The documentation for this class was generated from the following files: