InAppWebViewFlutterPlugin constructor
InAppWebViewFlutterPlugin(
- Registrar registrar
Constructs a new instance of InAppWebViewFlutterPlugin.
Implementation
InAppWebViewFlutterPlugin(Registrar registrar) {
ui_web.platformViewRegistry.registerViewFactory(
'com.pichillilorenzo/flutter_inappwebview', (int viewId) {
var webView =
InAppWebViewWebElement(viewId: viewId, messenger: registrar);
WebPlatformManager.webViews.putIfAbsent(viewId, () => webView);
return webView.iframeContainer;
});
}