initial offline mode, hive setup, home display, mzansi rofile display completed
This commit is contained in:
parent
3d5fdde322
commit
f19a316be8
20 changed files with 981 additions and 304 deletions
|
|
@ -1,46 +0,0 @@
|
|||
import 'package:flutter/material.dart';
|
||||
import 'package:youtube_player_iframe/youtube_player_iframe.dart';
|
||||
|
||||
class MIHYTVideoPlayer extends StatefulWidget {
|
||||
final String videoYTLink;
|
||||
const MIHYTVideoPlayer({
|
||||
super.key,
|
||||
required this.videoYTLink,
|
||||
});
|
||||
|
||||
@override
|
||||
State<MIHYTVideoPlayer> createState() => _MIHYTVideoPlayerState();
|
||||
}
|
||||
|
||||
class _MIHYTVideoPlayerState extends State<MIHYTVideoPlayer> {
|
||||
late YoutubePlayerController _controller;
|
||||
|
||||
@override
|
||||
void dispose() {
|
||||
_controller.close();
|
||||
super.dispose();
|
||||
}
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
_controller = YoutubePlayerController(
|
||||
params: const YoutubePlayerParams(
|
||||
enableCaption: false,
|
||||
showControls: true,
|
||||
mute: false,
|
||||
showFullscreenButton: false,
|
||||
loop: false,
|
||||
),
|
||||
);
|
||||
_controller.loadVideoById(videoId: widget.videoYTLink);
|
||||
super.initState();
|
||||
}
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return YoutubePlayer(
|
||||
controller: _controller,
|
||||
aspectRatio: 16 / 9,
|
||||
);
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue