Google is committed to advancing racial equity for Black communities. See how.

dispose method

void dispose ()

Releases native resources held by SceneHost object in Flutter engine.

Implementation

void dispose() {
  if (usePlatformView) {
    final args = <String, dynamic>{'viewId': viewId};
    _platformViewChannel.invokeMethod('View.dispose', args);
    onUnavailable?.call(this);
  } else {
    _sceneHost.dispose();
    _sceneHost = null;
  }
}