Wayaer / fl_pip

flutter picture-in-picture plugin for ios and android
MIT License
19 stars 13 forks source link

iOS - App stops responding #8

Open boradparas opened 9 months ago

boradparas commented 9 months ago

@override void didChangeAppLifecycleState(AppLifecycleState state) { super.didChangeAppLifecycleState(state); if (state == AppLifecycleState.resumed) { FlPiP().enable( ios: const FlPiPiOSConfig( enabledWhenBackground: true, createNewEngine: true, ), ); unawaited(videoRoomStore.resumeAllListeners()); } else { videoRoomStore.pauseAllListeners(); } }

And when I do it on button click it works fine but in every case the video is shown for first 2 seconds and then PIP turns grey (2 problems)

Wayaer commented 9 months ago

This seems to be because after the app enters the background, the application is restricted by the ios system, and there is no solution at present, even if the background process is configured in xcode