Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] On orientation to landscape while video is being played, the video does not play, gets stuck #351

Open
minal2709 opened this issue Sep 3, 2020 · 5 comments
Assignees
Labels
bug Something isn't working

Comments

@minal2709
Copy link

Describe the bug
While the video is playing, if we change the orientation, the video shows a || pause in the center and does not play. even the pause button is not clickable.

To Reproduce
Play a video, change the orientation of the phone.

Expected behavior
It should continue playing in landscape mode

Screenshots

IMG_9408

Technical Details:

  • Device: one plus 2
  • OS: Android version 6.0.1
    tried on other android phones too, does not work.

Additional context

@minal2709 minal2709 added the bug Something isn't working label Sep 3, 2020
@csacchetti
Copy link

I also found this bug. In iOS it runs very good but in Android it has this problem. I put the api at 20, but the problem remains.

@zjamshidi
Copy link

I have the same problem on Android. When I change the orientation, the video pauses.

@minal2709
Copy link
Author

I also get this error:

[ERROR:flutter/lib/ui/ui_dart_state.cc(166)] Unhandled Exception: MissingPluginException(No implementation found for method evaluateJavascript on channel com.pichillilorenzo/flutter_inappwebview_1)
E/flutter (30387): #0 MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:159:7)
E/flutter (30387):
E/flutter (30387): #1 MethodChannel.invokeMethod (package:flutter/src/services/platform_channel.dart:334:12)
E/flutter (30387): #2 InAppWebViewController.evaluateJavascript (package:flutter_inappwebview/src/in_app_webview_controller.dart:1350:31)
E/flutter (30387): #3 YoutubePlayerController._callMethod (package:youtube_player_flutter/src/utils/youtube_player_controller.dart:173:32)
E/flutter (30387): #4 YoutubePlayerController.pause (package:youtube_player_flutter/src/utils/youtube_player_controller.dart:187:19)
E/flutter (30387): #5 _TestScreenState.getYoutubeWidget. (package:avtaar/screens/TestScreen.dart:79:21)
E/flutter (30387): #6 _YoutubePlayerBuilderState.didChangeMetrics (package:youtube_player_flutter/src/widgets/youtube_player_builder.dart:60:67)
E/flutter (30387): #7 WidgetsBinding.handleMetricsChanged (package:flutter/src/widgets/binding.dart:540:16)
E/flutter (30387): #8 _rootRun (dart:async/zone.dart:1190:13)
E/flutter (30387): #9 _CustomZone.run (dart:async/zone.dart:1093:19)
E/flutter (30387): #10 _CustomZone.runGuarded (dart:async/zone.dart:997:7)
E/flutter (30387): #11 _invoke (dart:ui/hooks.dart:253:10)
E/flutter (30387): #12 _updateWindowMetrics (dart:ui/hooks.dart:55:3)

@MrJohn2014
Copy link

Same issue here. Also i tried code below. It works just on ios, but not on android devices. Please solve this bug.
onEnterFullScreen: (){
Future.delayed(const Duration(seconds: 1), () {
_controller.play();
});
},

@sallypeters
Copy link

I have the reverse of this issue - When we rotate to Landscape - no issue, video plays straight away ... but when we rotate back to Portrait , the video stops and we need to manually press the play button ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants