Skip to content

Commit fbd1866

Browse files
fix: ui.platformViewRegistry.registerViewFactory fixed (#2399)
#2360 (comment) Flutter web Error: Undefined name 'platformViewRegistry' #2360 #2360 Fixed
1 parent b2f2473 commit fbd1866

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

lib/src/impl/platform/web/global_video_view_controller_platform_web.dart

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import 'dart:async';
22
import 'dart:html' as html;
3-
import 'dart:ui' as ui;
3+
import 'dart:ui_web' as ui_web;
44

55
import '/agora_rtc_engine.dart';
66
import '/src/impl/platform/global_video_view_controller_platform.dart';
@@ -49,8 +49,7 @@ class GlobalVideoViewControllerWeb extends GlobalVideoViewControllerPlatfrom {
4949
GlobalVideoViewControllerWeb(
5050
IrisMethodChannel irisMethodChannel, RtcEngine rtcEngine)
5151
: super(irisMethodChannel, rtcEngine) {
52-
// ignore: undefined_prefixed_name
53-
ui.platformViewRegistry.registerViewFactory(_platformRendererViewType,
52+
ui_web.platformViewRegistry.registerViewFactory(_platformRendererViewType,
5453
(int viewId) {
5554
final view = _View(viewId);
5655
_viewMap[viewId] = view;

0 commit comments

Comments
 (0)