From 366eef1924e89a6f3134648e70f1808f04f49344 Mon Sep 17 00:00:00 2001 From: HUI Date: Mon, 17 May 2021 18:17:52 +0800 Subject: [PATCH] chore: optimize import --- lib/agora_rtc_engine_web.dart | 1 - lib/rtc_local_view.dart | 4 ++-- lib/rtc_remote_view.dart | 4 ++-- lib/src/enums.dart | 1 - lib/src/rtc_channel.dart | 4 +--- lib/src/rtc_engine.dart | 1 - lib/src/rtc_render_view.dart | 2 -- 7 files changed, 5 insertions(+), 12 deletions(-) diff --git a/lib/agora_rtc_engine_web.dart b/lib/agora_rtc_engine_web.dart index 59939e20d..8523963ea 100644 --- a/lib/agora_rtc_engine_web.dart +++ b/lib/agora_rtc_engine_web.dart @@ -1,5 +1,4 @@ import 'dart:async'; - // In order to *not* need this ignore, consider extracting the "web" version // of your plugin as a separate package, instead of inlining it in the same // package as the core of your plugin. diff --git a/lib/rtc_local_view.dart b/lib/rtc_local_view.dart index 686b90c54..575e45a65 100644 --- a/lib/rtc_local_view.dart +++ b/lib/rtc_local_view.dart @@ -3,8 +3,8 @@ import 'package:flutter/gestures.dart'; import 'package:flutter/services.dart'; import 'package:flutter/widgets.dart'; -import './src/enums.dart'; -import './src/rtc_render_view.dart'; +import 'src/enums.dart'; +import 'src/rtc_render_view.dart'; /// SurfaceView. class SurfaceView extends RtcSurfaceView { diff --git a/lib/rtc_remote_view.dart b/lib/rtc_remote_view.dart index e2a8a8fcf..c0aff00c3 100644 --- a/lib/rtc_remote_view.dart +++ b/lib/rtc_remote_view.dart @@ -2,8 +2,8 @@ import 'package:flutter/foundation.dart'; import 'package:flutter/gestures.dart'; import 'package:flutter/services.dart'; -import './src/enums.dart'; -import './src/rtc_render_view.dart'; +import 'src/enums.dart'; +import 'src/rtc_render_view.dart'; /// SurfaceView. class SurfaceView extends RtcSurfaceView { diff --git a/lib/src/enums.dart b/lib/src/enums.dart index fc8447a1f..c71081527 100644 --- a/lib/src/enums.dart +++ b/lib/src/enums.dart @@ -1,7 +1,6 @@ import 'package:json_annotation/json_annotation.dart'; import 'events.dart'; -import 'rtc_engine.dart'; /// The area of connection. enum AreaCode { diff --git a/lib/src/rtc_channel.dart b/lib/src/rtc_channel.dart index bc6d358a1..30c1f1888 100644 --- a/lib/src/rtc_channel.dart +++ b/lib/src/rtc_channel.dart @@ -6,7 +6,6 @@ import 'classes.dart'; import 'enum_converter.dart'; import 'enums.dart'; import 'events.dart'; -import 'rtc_engine.dart'; /// The RtcChannel class. class RtcChannel with RtcChannelInterface { @@ -316,8 +315,7 @@ class RtcChannel with RtcChannelInterface { @override Future createDataStreamWithConfig(DataStreamConfig config) { - return _invokeMethod( - 'createDataStream', {'config': config.toJson()}); + return _invokeMethod('createDataStream', {'config': config.toJson()}); } @override diff --git a/lib/src/rtc_engine.dart b/lib/src/rtc_engine.dart index e79dab59b..5f86ccef8 100644 --- a/lib/src/rtc_engine.dart +++ b/lib/src/rtc_engine.dart @@ -2,7 +2,6 @@ import 'dart:async'; import 'package:flutter/services.dart'; -import '../rtc_local_view.dart'; import 'classes.dart'; import 'enum_converter.dart'; import 'enums.dart'; diff --git a/lib/src/rtc_render_view.dart b/lib/src/rtc_render_view.dart index 6fda1ba5e..7425f79ce 100644 --- a/lib/src/rtc_render_view.dart +++ b/lib/src/rtc_render_view.dart @@ -6,8 +6,6 @@ import 'package:flutter/widgets.dart'; import 'enum_converter.dart'; import 'enums.dart'; -import 'rtc_channel.dart'; -import 'rtc_engine.dart'; final Map _channels = {};