How to exit fullscreen by pressing phone's back key.
使用chewie插件,发现视频全屏播放状态下,按手机返回键不是退出全屏,而是返回上一个页面。如何设置,全屏播放状态下,按手机返回键退出全屏而不是返回上一个页面。
(google translate) Use chewie plug-in and find that when the video is playing in full screen, pressing the mobile phone's return key does not exit the full screen, but returns to the previous page. How to set, in full-screen playback state, press the phone's back key to exit full screen instead of returning to the previous page.
Please add a full example where you see this problem.
(请在出现此问题的地方添加一个完整的示例。)
使用chewie插件,发现视频全屏播放状态下,按手机返回键不是退出全屏,而是返回上一个页面。如何设置,全屏播放状态下,按手机返回键退出全屏而不是返回上一个页面。
(google translate)
Use chewie plug-in and find that when the video is playing in full screen, pressing the mobile phone's return key does not exit the full screen, but returns to the previous page. How to set, in full-screen playback state, press the phone's back key to exit full screen instead of returning to the previous page.
@yslings Very good issue here! 👏🏻 I encountered the same. I'll have a look into the code and try to add WillPopScope
I've set autoPlay to true and fullScreenByDefault to true, first press on Back button exits full screen but immediately goes back to full screen, second press exits full screen and the third button exits the screen
[Android]
@Ahmadre Any updates..? Not only this issue, I just tried to put WillPopScope on the Scaffold where the grand children has Chewie.
When the player isn't playing, it works normal but when the Chewie is playing a video, it rebuilds itself and pauses the video from playing.
Just discovered another thiing.. same sourse as above, clicking on back button in the app bar works as normal, but the device back key pressing works abnormal...