migração flutter 2.2.1
This commit is contained in:
@@ -5,19 +5,19 @@ import 'api/youtube_classes.dart';
|
||||
|
||||
class YouTubeVideoPlayerScreen extends StatefulWidget {
|
||||
final YouTubeItems ytVideo;
|
||||
YouTubeVideoPlayerScreen({@required this.ytVideo});
|
||||
YouTubeVideoPlayerScreen({required this.ytVideo});
|
||||
@override
|
||||
_YouTubeVideoPlayerScreenState createState() => _YouTubeVideoPlayerScreenState();
|
||||
}
|
||||
|
||||
class _YouTubeVideoPlayerScreenState extends State<YouTubeVideoPlayerScreen> {
|
||||
|
||||
YoutubePlayerController _controller;
|
||||
late YoutubePlayerController _controller;
|
||||
bool _fullScreen = false;
|
||||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
_controller = new YoutubePlayerController(initialVideoId: widget.ytVideo.id.videoId);
|
||||
_controller = new YoutubePlayerController(initialVideoId: widget.ytVideo.id!.videoId!);
|
||||
}
|
||||
|
||||
@override
|
||||
@@ -58,9 +58,9 @@ class _YouTubeVideoPlayerScreenState extends State<YouTubeVideoPlayerScreen> {
|
||||
padding: const EdgeInsets.all(8.0),
|
||||
child: Column(
|
||||
children: [
|
||||
Text(widget.ytVideo.snippet.title),
|
||||
Text(widget.ytVideo.snippet!.title!),
|
||||
SizedBox(height: 10.0,),
|
||||
Text(widget.ytVideo.snippet.description),
|
||||
Text(widget.ytVideo.snippet!.description!),
|
||||
],
|
||||
),
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user