Merge branch 'main' into fix
This commit is contained in:
@ -768,37 +768,33 @@ class _PLVideoPlayerState extends State<PLVideoPlayer>
|
|||||||
),
|
),
|
||||||
|
|
||||||
// 头部、底部控制条
|
// 头部、底部控制条
|
||||||
SafeArea(
|
Obx(
|
||||||
top: false,
|
() => Column(
|
||||||
bottom: false,
|
children: [
|
||||||
child: Obx(
|
if (widget.headerControl != null || _.headerControl != null)
|
||||||
() => Column(
|
|
||||||
children: [
|
|
||||||
if (widget.headerControl != null || _.headerControl != null)
|
|
||||||
ClipRect(
|
|
||||||
child: AppBarAni(
|
|
||||||
controller: animationController,
|
|
||||||
visible: !_.controlsLock.value && _.showControls.value,
|
|
||||||
position: 'top',
|
|
||||||
child: widget.headerControl ?? _.headerControl!,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
const Spacer(),
|
|
||||||
ClipRect(
|
ClipRect(
|
||||||
child: AppBarAni(
|
child: AppBarAni(
|
||||||
controller: animationController,
|
controller: animationController,
|
||||||
visible: !_.controlsLock.value && _.showControls.value,
|
visible: !_.controlsLock.value && _.showControls.value,
|
||||||
position: 'bottom',
|
position: 'top',
|
||||||
child: widget.bottomControl ??
|
child: widget.headerControl ?? _.headerControl!,
|
||||||
BottomControl(
|
|
||||||
controller: widget.controller,
|
|
||||||
triggerFullScreen: _.triggerFullScreen,
|
|
||||||
buildBottomControl: buildBottomControl(),
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
const Spacer(),
|
||||||
),
|
ClipRect(
|
||||||
|
child: AppBarAni(
|
||||||
|
controller: animationController,
|
||||||
|
visible: !_.controlsLock.value && _.showControls.value,
|
||||||
|
position: 'bottom',
|
||||||
|
child: widget.bottomControl ??
|
||||||
|
BottomControl(
|
||||||
|
controller: widget.controller,
|
||||||
|
triggerFullScreen: _.triggerFullScreen,
|
||||||
|
buildBottomControl: buildBottomControl(),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
||||||
|
|||||||
@ -29,6 +29,10 @@ class AppBarAni extends StatelessWidget implements PreferredSizeWidget {
|
|||||||
curve: Curves.linear,
|
curve: Curves.linear,
|
||||||
)),
|
)),
|
||||||
child: Container(
|
child: Container(
|
||||||
|
padding: EdgeInsets.only(
|
||||||
|
left: MediaQuery.of(context).padding.left,
|
||||||
|
right: MediaQuery.of(context).padding.right,
|
||||||
|
),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
gradient: position! == 'top'
|
gradient: position! == 'top'
|
||||||
? const LinearGradient(
|
? const LinearGradient(
|
||||||
|
|||||||
Reference in New Issue
Block a user