MPNavigatorObserverPrivate constructor

MPNavigatorObserverPrivate()

Implementation

MPNavigatorObserverPrivate() {
  if (!kIsMPFlutter) {
    return;
  }
  js.context["androidBackPressed"] = () {
    final ctx = navigator?.context;
    if (ctx != null && Navigator.canPop(ctx)) {
      Navigator.maybePop(ctx);
    }
  };
  shared = this;
}