-
Notifications
You must be signed in to change notification settings - Fork 917
Open
Description
Is there an existing issue for this?
- I have searched the existing issues
Package
youtube_player_flutter
What happened?
When you click to view in fullscreen, the entire app rotates to landscape.
What is the expected behaviour?
Only landscape the video to see it in fullscreen, not the whole app.
How to reproduce?
youtube_player_flutter: ^9.1.1
class YouTubeVideoPlayer extends StatefulWidget {
final String youtubeId;
const YouTubeVideoPlayer({required this.youtubeId, super.key});
@override
State<YouTubeVideoPlayer> createState() => _YouTubeVideoPlayerState();
}
class _YouTubeVideoPlayerState extends State<YouTubeVideoPlayer> {
late YoutubePlayerController _controller;
@override
void initState() {
super.initState();
_controller = YoutubePlayerController(
initialVideoId: widget.youtubeId,
flags: YoutubePlayerFlags(autoPlay: true),
);
}
@override
Widget build(BuildContext context) {
return YoutubePlayerBuilder(
player: YoutubePlayer(controller: _controller),
builder: (context, player) {
return Column(
children: [
player,
],
);
},
);
}
}
Flutter Doctor Output
[√] Flutter (Channel stable, 3.29.3, on Microsoft Windows [Versi¢n 10.0.22621.4317], locale es-US) [1,640ms]
• Flutter version 3.29.3 on channel stable at C:\src\flutter
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision ea121f8859 (3 weeks ago), 2025-04-11 19:10:07 +0000
• Engine revision cf56914b32
• Dart version 3.7.2
• DevTools version 2.42.3
[√] Windows Version (11 Pro 64 bits, 22H2, 2009) [4.2s]
[√] Android toolchain - develop for Android devices (Android SDK version 34.0.0) [10.2s]
• Android SDK at [...]
• Platform android-35, build-tools 34.0.0
• Java binary at: C:\Program Files\Android\Android Studio\jbr\bin\java
This is the JDK bundled with the latest Android Studio installation on this machine.
To manually set the JDK path, use: `flutter config --jdk-dir="path/to/jdk"`.
• Java version OpenJDK Runtime Environment (build 21.0.5+-13047016-b750.29)
• All Android licenses accepted.
[√] Chrome - develop for the web [1,069ms]
• Chrome at C:\Program Files\Google\Chrome\Application\chrome.exe
[X] Visual Studio - develop Windows apps [1,068ms]
X Visual Studio not installed; this is necessary to develop Windows apps.
Download at https://visualstudio.microsoft.com/downloads/.
Please install the "Desktop development with C++" workload, including all of its default components
[√] Android Studio (version 2024.3) [37ms]
• Android Studio at C:\Program Files\Android\Android Studio
• Flutter plugin can be installed from:
https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin can be installed from:
https://plugins.jetbrains.com/plugin/6351-dart
• Java version OpenJDK Runtime Environment (build 21.0.5+-13047016-b750.29)
[√] VS Code (version 1.99.3) [34ms]
• VS Code at C:\Users\...\AppData\Local\Programs\Microsoft VS Code
• Flutter extension version 3.110.0
[√] Connected device (4 available) [668ms]
• (mobile) • ... • android-arm64 • Android 13 (API 33)
[√] Network resources [1,525ms]
• All expected network resources are available.
Fudal, tihomir-kit, MaddieThms, japatel225 and leonardmataseljapatel225
Metadata
Metadata
Assignees
Labels
No labels