ensureFrameCallbacksRegistered method Null safety

  1. @protected
void ensureFrameCallbacksRegistered()

Ensures callbacks for PlatformDispatcher.onBeginFrame and PlatformDispatcher.onDrawFrame are registered.

Implementation

@protected
void ensureFrameCallbacksRegistered() {
  window.onBeginFrame ??= _handleBeginFrame;
  window.onDrawFrame ??= _handleDrawFrame;
}