@ -1,6 +1,7 @@
import ' dart:async ' ;
import ' dart:async ' ;
import ' dart:convert ' ;
import ' dart:convert ' ;
import ' dart:ui ' ;
import ' dart:ui ' ;
import ' dart:io ' ;
import ' package:flutter/material.dart ' ;
import ' package:flutter/material.dart ' ;
import ' package:flutter/services.dart ' ;
import ' package:flutter/services.dart ' ;
@ -12,12 +13,11 @@ import 'package:hyzp_ybqx/components/dioFun.dart';
import ' package:hyzp_ybqx/provider/player_ratio.dart ' ;
import ' package:hyzp_ybqx/provider/player_ratio.dart ' ;
import ' package:hyzp_ybqx/provider/player_region.dart ' ;
import ' package:hyzp_ybqx/provider/player_region.dart ' ;
import ' package:provider/provider.dart ' ;
import ' package:provider/provider.dart ' ;
import ' package:fijkplayer/fijkplayer.dart ' ;
import ' ../components/commonFun.dart ' ;
import ' ../components/commonFun.dart ' ;
import ' ../services/Storage.dart ' ;
import ' ../services/Storage.dart ' ;
const _kControlViewTypes = [ kControlViewTypeDefault , kControlViewTypeWithout ] ;
class SuperPlayerPage extends StatefulWidget {
class SuperPlayerPage extends StatefulWidget {
SuperPlayerPage (
SuperPlayerPage (
{ @ required this . url ,
{ @ required this . url ,
@ -38,31 +38,28 @@ class SuperPlayerPage extends StatefulWidget {
}
}
class _SuperPlayerPageState extends State < SuperPlayerPage > with SuperPlayerListener {
class _SuperPlayerPageState extends State < SuperPlayerPage > with SuperPlayerListener {
SuperPlayerController _playerController = SuperPlayerController ( ) ;
final SuperPlayerController _playerController = SuperPlayerController ( ) ;
final FijkPlayer _ijkPlayer = FijkPlayer ( ) ;
String _sdkVersion = ' Unknown ' ;
String _sdkVersion = ' Unknown ' ;
List < String > _logs = [ ] ;
List < String > _logs = [ ] ;
bool bFullScreen = false ;
bool bFullScreen = false ;
String _controlViewType = _kControlViewTypes . first ;
@ override
@ override
void dispose ( ) {
void dispose ( ) {
Playing = false ;
Playing = false ;
/ / 云 台 控 制 代 码 : 1 : 停 止 动 作 、 3 : 启 动 雨 刷 、 11 : 焦 距 变 大 、 12 : 焦 距 变 小
/ / 云 台 控 制 代 码 : 1 : 停 止 动 作 、 3 : 启 动 雨 刷 、 11 : 焦 距 变 大 、 12 : 焦 距 变 小
setSphericalCameraDio ( id: widget . id , dwip: widget . dwip , cmdCode: 1 ) ;
setSphericalCameraDio ( id: widget . id , dwip: widget . dwip , cmdCode: 1 ) ;
super . dispose ( ) ;
super . dispose ( ) ;
_ijkPlayer . release ( ) ;
_playerController . resetPlayer ( ) ;
_playerController . release ( ) ;
SystemChrome . setPreferredOrientations ( [ DeviceOrientation . portraitUp ] ) ;
}
}
@ override
@ override
void initState ( ) {
void initState ( ) {
super . initState ( ) ;
super . initState ( ) ;
/ / initPlatformState ( ) ;
/ / Future . delayed ( const Duration ( milliseconds: 1000 ) , ( ) {
/ / _playerController . playWithModel ( SuperPlayerModel ( url: widget . url ) ) ;
/ / setState ( ( ) {
/ / } ) ;
/ / } ) ;
init ( ) ;
init ( ) ;
}
}
@ -70,38 +67,26 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
await _playerController . addListener ( this ) ;
await _playerController . addListener ( this ) ;
await initPlatformState ( ) ;
await initPlatformState ( ) ;
if ( ! mounted ) return ;
if ( ! mounted ) return ;
print ( ' mounted = ${ mounted } ' ) ;
/ / 开 启 调 试 日 志
/ / await FTXPlayerController . setConsoleEnabled ( true ) ;
/ / 初 始 化 播 放 器
/ / await _controller . initialize ( onlyAudio: true ) ;
await _playerController . uiHideDanmu ( ) ; / / 隐 藏 弹 幕
if ( _useIJKPlayer ) {
/ / 设 置 播 放 循 环 , 默 认 播 放 器 的 循 环 次 数 是 1 , 即 不 循 环 播 放 。 如 果 设 置 循 环 次 数 0 , 表 示 无 限 循 环 。
await _playerController . removeListener ( this ) ;
_ijkPlayer . addListener ( _fijkValueListener ) ;
_ijkPlayer . setDataSource ( widget . url , autoPlay: true ) ;
} else {
await _playerController . uiHideDanmu ( ) ;
if ( 0 = = widget . loop ) {
if ( 0 = = widget . loop ) {
await _playerController . setLoop ( true ) ;
await _playerController . setLoop ( true ) ;
}
}
await _playerController . playWithModel ( testSuperPlayerModel ) ;
await _playerController . playWithModel ( testSuperPlayerModel ) ;
/ / _controller . play ( " http://clips.vorwaerts-gmbh.de/big_buck_bunny.mp4 " ) ;
}
/ / _controller
/ / . play ( ' rtmp://125.64.218.67:9901/rtp/gb_play_34020000001320003016_34020000001320003016 ' ) ;
/ / 设 置 循 环 播 放
/ / await _controller . setLoop ( true ) ;
/ / 开 始 播 放
/ / await _controller . play ( " http://125.64.218.67:9908/video/2_6063_20210409_140608_川Q31715.mp4 " ) ;
}
}
SuperPlayerModel get testSuperPlayerModel {
bool get _useIJKPlayer {
/ / int appId = 1252463788 ;
return Platform . isIOS & & widget . url . startsWith ( " rtmp " ) ;
/ / String fileId = " 5285890781763144364 " ;
}
SuperPlayerModel superPlayerModel = SuperPlayerModel (
SuperPlayerModel get testSuperPlayerModel {
url: widget . url ,
return SuperPlayerModel ( url: widget . url ) ;
/ / appId: appId ,
/ / videoId: SuperPlayerVideoId ( fileId: fileId ) ,
) ;
return superPlayerModel ;
}
}
/ / Platform messages are asynchronous , so we initialize in an async method .
/ / Platform messages are asynchronous , so we initialize in an async method .
@ -157,7 +142,6 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
double _outerRadius = 270 ;
double _outerRadius = 270 ;
double _innerRadius = _outerRadius / 2 ;
double _innerRadius = _outerRadius / 2 ;
/ / double barHeight = bFullScreen ? 0 : MediaQueryData . fromWindow ( window ) . padding . top ;
return Scaffold (
return Scaffold (
appBar: bFullScreen
appBar: bFullScreen
? null
? null
@ -168,13 +152,9 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
automaticallyImplyLeading: false ,
automaticallyImplyLeading: false ,
centerTitle: true ,
centerTitle: true ,
titleSpacing: 0.0 ,
titleSpacing: 0.0 ,
/ / 设 置 title 的 左 边 距
flexibleSpace: Container (
flexibleSpace: Container (
/ / SizedBox ( height: ScreenUtil ( ) . statusBarHeight ) , / / 显 示 顶 部 状 态 栏
/ / SizedBox ( height: ScreenUtil ( ) . setHeight ( 10 ) ) , / / 显 示 顶 部 状 态 栏
padding: EdgeInsets . only ( top: ScreenUtil ( ) . statusBarHeight ) , / / 留 出 顶 部 状 态 栏 高 度
padding: EdgeInsets . only ( top: ScreenUtil ( ) . statusBarHeight ) , / / 留 出 顶 部 状 态 栏 高 度
child: Container (
child: Container (
/ / height: ScreenUtil ( ) . setHeight ( 173 ) ,
decoration: BoxDecoration (
decoration: BoxDecoration (
gradient: LinearGradient (
gradient: LinearGradient (
begin: Alignment . centerLeft ,
begin: Alignment . centerLeft ,
@ -185,12 +165,6 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
] ,
] ,
) ,
) ,
) ,
) ,
/ / decoration: BoxDecoration (
/ / gradient: LinearGradient ( colors: [
/ / Color ( 0xFF0018EB ) ,
/ / Color ( 0xFF01C1D9 ) ,
/ / ] , begin: Alignment . bottomCenter , end: Alignment . topCenter ) ,
/ / ) ,
) ,
) ,
) ,
) ,
title: Padding (
title: Padding (
@ -203,7 +177,7 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
iconData: Icons . chevron_left_outlined ,
iconData: Icons . chevron_left_outlined ,
onPress: ( ) {
onPress: ( ) {
getingDwVideo = false ;
getingDwVideo = false ;
Navigator. pop( context ) ;
pop( ) ;
} ,
} ,
) ,
) ,
Expanded (
Expanded (
@ -220,16 +194,12 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
) ,
) ,
body: WillPopScope (
body: WillPopScope (
child: Container (
child: Container (
/ / height: ScreenUtil ( ) . screenHeight -
/ / ScreenUtil ( ) . statusBarHeight -
/ / ScreenUtil ( ) . bottomBarHeight ,
color: Color . fromRGBO ( 224 , 224 , 224 , 1 ) ,
color: Color . fromRGBO ( 224 , 224 , 224 , 1 ) ,
child: Column (
child: Column (
children: < Widget > [
children: < Widget > [
/ / 第 2 行 组 件 , 视 频 播 放 区
/ / 第 2 行 组 件 , 视 频 播 放 区
Center (
Center (
child: Container (
child: Container (
/ / padding: EdgeInsets . only ( top: barHeight ) ,
alignment: Alignment ( 0 , - 1 ) ,
alignment: Alignment ( 0 , - 1 ) ,
width: MediaQuery . of ( context ) . size . width ,
width: MediaQuery . of ( context ) . size . width ,
height: MediaQuery . of ( context ) . size . width * ( 9 / 16 ) ,
height: MediaQuery . of ( context ) . size . width * ( 9 / 16 ) ,
@ -237,11 +207,7 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
child: Stack (
child: Stack (
children: [
children: [
_playState < = 2 ? getMoreWidget ( strokeWidth: 3.0 ) : SizedBox . shrink ( ) ,
_playState < = 2 ? getMoreWidget ( strokeWidth: 3.0 ) : SizedBox . shrink ( ) ,
SuperPlayerView (
_useIJKPlayer ? FijkView ( player: _ijkPlayer ) : SuperPlayerView ( controller: _playerController )
controller: _playerController ,
controlViewType: _kControlViewTypes [ 0 ] ,
) ,
/ / _playState < 3 ? SizedBox . shrink ( ) : getMoreWidget ( strokeWidth: 3.0 ) ,
] ,
] ,
) ,
) ,
) ,
) ,
@ -254,7 +220,6 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
children: [
children: [
SizedBox ( width: ScreenUtil ( ) . setWidth ( btn_left ) ) ,
SizedBox ( width: ScreenUtil ( ) . setWidth ( btn_left ) ) ,
getRoundButton (
getRoundButton (
/ / ( bPlaying ) ? ' 暂停 ' : ' 播放 ' ,
text: playerRegionProvide . playerText ,
text: playerRegionProvide . playerText ,
icon: playerRegionProvide . playerIcon ,
icon: playerRegionProvide . playerIcon ,
diameter: 130 ,
diameter: 130 ,
@ -407,41 +372,27 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
}
}
} ,
} ,
) ,
) ,
/ / child: GridView . custom (
) ,
/ / / / padding: EdgeInsets . only (
/ / / / left: ScreenUtil ( ) . setWidth ( 35 ) , right: ScreenUtil ( ) . setWidth ( 35 ) ) ,
/ / gridDelegate: SliverGridDelegateWithFixedCrossAxisCount (
/ / crossAxisCount: btnCount3 ,
/ / mainAxisSpacing: 0 ,
/ / crossAxisSpacing: 1 ,
/ / childAspectRatio: ratio3 ,
/ / ) ,
/ / childrenDelegate: SliverChildBuilderDelegate ( ( context , position ) {
/ / return getItemContainer ( listData [ position ] ) ;
/ / } , childCount: btnCount3 ) ) ,
) ,
/ / SizedBox ( height: ScreenUtil ( ) . setHeight ( 49 ) ) ,
/ / Divider ( color: Colors . blue ) ,
/ / 第 4 行 组 件 , 分 隔 栏
/ / Container (
/ / / / height: 11 ,
/ / height: ScreenUtil ( ) . setHeight ( 28 ) ,
/ / color: Color . fromRGBO ( 224 , 224 , 224 , 1 ) ,
/ / ) ,
] ,
] ,
) ,
) ,
) ,
) ,
onWillPop: ( ) {
onWillPop: ( ) {
Playing = false ;
getingDwVideo = false ;
/ / 云 台 控 制 代 码 : 1 : 停 止 动 作 、 3 : 启 动 雨 刷 、 11 : 焦 距 变 大 、 12 : 焦 距 变 小
/ / 云 台 控 制 代 码 : 1 : 停 止 动 作 、 3 : 启 动 雨 刷 、 11 : 焦 距 变 大 、 12 : 焦 距 变 小
setSphericalCameraDio ( id: widget . id , dwip: widget . dwip , cmdCode: 1 ) ;
setSphericalCameraDio ( id: widget . id , dwip: widget . dwip , cmdCode: 1 ) ;
Navigator. pop( context ) ; / / 关 闭 弹 框 , 播 放 输 入 视 频 地 址
pop ( ) ;
} ,
} ,
) ,
) ,
) ;
) ;
}
}
pop ( ) async {
Playing = false ;
getingDwVideo = false ;
_ijkPlayer . removeListener ( ( ) { } ) ;
await _playerController . removeListener ( this ) ;
Navigator . pop ( context ) ;
}
@ override
@ override
void onClickFloatCloseBtn ( ) {
void onClickFloatCloseBtn ( ) {
_addLog ( ' onClickFloatCloseBtn ' , { } ) ;
_addLog ( ' onClickFloatCloseBtn ' , { } ) ;
@ -450,7 +401,7 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
@ override
@ override
void onClickSmallReturnBtn ( ) {
void onClickSmallReturnBtn ( ) {
_addLog ( ' onClickSmallReturnBtn ' , { } ) ;
_addLog ( ' onClickSmallReturnBtn ' , { } ) ;
Navigator. maybePop ( context ) ;
pop( ) ;
}
}
@ override
@ override
@ -496,6 +447,12 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
_addLog ( ' onStartFloatWindowPlay ' , { } ) ;
_addLog ( ' onStartFloatWindowPlay ' , { } ) ;
}
}
void _fijkValueListener ( ) {
FijkValue value = _ijkPlayer . value ;
onPlayStateChange ( value . state = = FijkState . started ? 1 : 2 ) ;
onFullScreenChange ( value . fullScreen ) ;
}
/ / 生 成 圆 形 按 钮 部 件 , 基 于 图 标
/ / 生 成 圆 形 按 钮 部 件 , 基 于 图 标
Widget getRoundButton (
Widget getRoundButton (
{ double diameter = 144 ,
{ double diameter = 144 ,
@ -554,13 +511,7 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
child: Image . asset ( image_path ,
child: Image . asset ( image_path ,
fit: BoxFit . fitWidth ,
fit: BoxFit . fitWidth ,
width: ScreenUtil ( ) . setWidth ( imageSize ) ,
width: ScreenUtil ( ) . setWidth ( imageSize ) ,
/ / height: ScreenUtil ( ) . setWidth ( iconSize ) ,
color: Color . fromRGBO ( 52 , 157 , 237 , 1 ) ) ,
color: Color . fromRGBO ( 52 , 157 , 237 , 1 ) ) ,
/ / child: Icon (
/ / icon ,
/ / size: ScreenUtil ( ) . setWidth ( iconSize ) ,
/ / color: Color . fromRGBO ( 52 , 157 , 237 , 1 ) ,
/ / ) ,
decoration: BoxDecoration (
decoration: BoxDecoration (
color: color_bkg ,
color: color_bkg ,
borderRadius: BorderRadius . all ( Radius . circular ( 200 ) ) ,
borderRadius: BorderRadius . all ( Radius . circular ( 200 ) ) ,
@ -576,44 +527,37 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
bool bPlaying = true ;
bool bPlaying = true ;
void playOrPause ( ) {
Future < void > playOrPause ( ) async {
/ / state : 1 播 放 状 态 , 2 暂 停 状 态
/ / state : 1 播 放 状 态 , 2 暂 停 状 态
_playerController . getPlayState ( ) . then ( ( state ) {
int state ;
print ( ' state = $ state ' ) ;
if ( _useIJKPlayer ) {
state = _ijkPlayer . state = = FijkState . started ? 1 : 2 ;
} else {
state = await _playerController . getPlayState ( ) ;
}
if ( 1 = = state ) {
if ( 1 = = state ) {
bPlaying = false ;
bPlaying = false ;
_playerController . pause ( ) ;
_useIJKPlayer ? _ijkPlayer . pause ( ) : _playerController . pause ( ) ;
} else {
} else {
bPlaying = true ;
bPlaying = true ;
_playerController . resume ( ) ;
_useIJKPlayer ? _ijkPlayer . start ( ) : _playerController . resume ( ) ;
}
}
playerRegionProvide . changePlayerState ( bPlaying ) ;
playerRegionProvide . changePlayerState ( bPlaying ) ;
Storage . setString ( ' bPlaying ' , bPlaying ? ' true ' : ' false ' ) ;
Storage . setString ( ' bPlaying ' , bPlaying ? ' true ' : ' false ' ) ;
setState ( ( ) { } ) ;
setState ( ( ) { } ) ;
} ) ;
}
}
void restartPlay ( String url ) async {
void restartPlay ( String url ) async {
_playState = 4 ;
_playState = 4 ;
bPlaying = true ;
bPlaying = true ;
if ( _useIJKPlayer ) {
await _ijkPlayer . reset ( ) ;
_ijkPlayer . setDataSource ( widget . url , autoPlay: true ) ;
} else {
_playerController . resetPlayer ( ) ;
_playerController . resetPlayer ( ) ;
_playerController . resume ( ) ;
_playerController . resume ( ) ;
/ / / / writeCurrentPosFile ( ) ;
}
/ / await player . stop ( ) ;
/ / await player . reset ( ) ;
/ / await player . setOption ( FijkOption . playerCategory , " mediacodec-all-videos " , 1 ) ;
/ / await player . setOption ( FijkOption . hostCategory , " enable-snapshot " , 1 ) ;
/ / await player . setOption ( FijkOption . hostCategory , " request-screen-on " , 1 ) ;
/ / await player . setOption ( FijkOption . hostCategory , " request-audio-focus " , 1 ) ;
/ / await player . setOption ( FijkOption . hostCategory , " enable-accurate-seek " , 1 ) ;
/ / await player . setOption ( FijkOption . hostCategory , " max-buffer-size " , 500 * 1024 ) ;
/ / await player . setDataSource ( url , autoPlay: true ) . catchError ( ( e ) {
/ / print ( " setDataSource error: $ e " ) ;
/ / } ) ;
/ / await player . setLoop ( widget . loop ) ; / / 设 置 播 放 循 环 , 默 认 播 放 器 的 循 环 次 数 是 1 , 即 不 循 环 播 放 。 如 果 设 置 循 环 次 数 0 , 表 示 无 限 循 环 。
/ / bPlaying = true ;
/ / setState ( ( ) { } ) ;
/ / playerRegionProvide . changePlayerState ( bPlaying ) ;
}
}
/ / 生 成 播 放 控 制 区 第 2 行 按 钮 List
/ / 生 成 播 放 控 制 区 第 2 行 按 钮 List
@ -624,24 +568,6 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
double _marginVer = 8 ;
double _marginVer = 8 ;
List < Widget > list = [
List < Widget > list = [
/ / getRoundButton (
/ / diameter: _diameter ,
/ / iconSize: _iconSize ,
/ / text: ' 快退 ' ,
/ / icon: Icons . fast_rewind ,
/ / onPress: ( ) {
/ / fastSeek ( false ) ;
/ / } ,
/ / ) ,
/ / getRoundButton (
/ / diameter: _diameter ,
/ / iconSize: _iconSize ,
/ / text: ' 快进 ' ,
/ / icon: Icons . fast_forward ,
/ / onPress: ( ) {
/ / fastSeek ( true ) ;
/ / } ,
/ / ) ,
getRoundButton (
getRoundButton (
diameter: _diameter ,
diameter: _diameter ,
iconSize: _iconSize ,
iconSize: _iconSize ,
@ -650,8 +576,6 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
text: ' 放大 ' ,
text: ' 放大 ' ,
icon: Icons . zoom_in ,
icon: Icons . zoom_in ,
onPress: ( ) {
onPress: ( ) {
/ / print ( ' Icons.videocam ' ) ;
/ / _inputDialog ( context2 ) ;
if ( 10 > = playerRatioProvide . scale ) {
if ( 10 > = playerRatioProvide . scale ) {
playerRatioProvide . changeScale ( playerRatioProvide . scale + 0.5 ) ;
playerRatioProvide . changeScale ( playerRatioProvide . scale + 0.5 ) ;
}
}
@ -665,27 +589,11 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
text: ' 缩小 ' ,
text: ' 缩小 ' ,
icon: Icons . zoom_out ,
icon: Icons . zoom_out ,
onPress: ( ) {
onPress: ( ) {
/ / print ( ' Icons.videocam ' ) ;
/ / _getFileDialog ( context2 ) ;
if ( 1 < playerRatioProvide . scale ) {
if ( 1 < playerRatioProvide . scale ) {
playerRatioProvide . changeScale ( playerRatioProvide . scale - 0.5 ) ;
playerRatioProvide . changeScale ( playerRatioProvide . scale - 0.5 ) ;
}
}
} ,
} ,
) ,
) ,
/ / _getIconAndTextButton (
/ / ' 还原 ' ,
/ / Icons . reply ,
/ / Colors . orange ,
/ / ( ) {
/ / / / print ( ' Icons.videocam ' ) ;
/ / / / _getFileDialog ( context2 ) ;
/ / / / 更 新 当 前 位 置
/ / playerRatioProvide . changeScale ( 1.0 ) ;
/ / playerRatioProvide . changeOffset ( Offset ( 0 , 0 ) ) ;
/ / playerRatioProvide . changeDeltaX ( 0.0 ) ;
/ / playerRatioProvide . changeDeltaY ( 0.0 ) ;
/ / } ,
/ / ) ,
getRoundButton (
getRoundButton (
diameter: _diameter ,
diameter: _diameter ,
iconSize: _iconSize ,
iconSize: _iconSize ,
@ -694,9 +602,6 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
text: ' 截图 ' ,
text: ' 截图 ' ,
icon: Icons . camera_alt ,
icon: Icons . camera_alt ,
onPress: ( ) {
onPress: ( ) {
/ / 通 过 上 面 定 义 的 key , 才 能 准 确 调 用 该 类 型 的 该 对 象 的 方 法
/ / _myFijkPanelWidgetBuilderStateKey . currentState . takeSnapshot ( ) ;
/ / _fijkPanelWidgetBuilder . currentState . . takeSnapshot ( ) ;
takeSnapshot ( ) ;
takeSnapshot ( ) ;
} ,
} ,
) ,
) ,
@ -708,8 +613,7 @@ class _SuperPlayerPageState extends State<SuperPlayerPage> with SuperPlayerListe
text: ' 全屏 ' ,
text: ' 全屏 ' ,
icon: Icons . fullscreen ,
icon: Icons . fullscreen ,
onPress: ( ) {
onPress: ( ) {
/ / player . enterFullScreen ( ) ;
_useIJKPlayer ? _ijkPlayer . enterFullScreen ( ) : _playerController . toFullScreen ( ) ;
_playerController . toFullScreen ( ) ;
} ,
} ,
) ,
) ,
] ;
] ;