how to call a callback when the user exits the application (but does not close it) to stop? I store the state in the block, I call the event to stop the Audio Player. When he leaves the screen, I use dispose, it works only when the user has left the screen
https://api.flutter.dev/flutter/widgets/AppLifecycleListener-class.html#:~:text=A%20listener%20that%20can%20be,and%20set%20the%20onExitRequested%20callback.
Обсуждают сегодня