The on_pause() and on_resume() methods of the main App class have been implemented as follows:
class FitnessApp(App):
def build(self):
return RootWidget()
def on_pause(self):
return True
def on_resume(self):
pass
Logcat output relating to the app from screen lock to unlock
06-15 22:16:35.494 5318 5613 D PowerCheckerService: foreground, uid = 10306, app = org.workouthelper.workouthelper
06-15 22:16:39.038 5318 5613 D PowerCheckerService: foreground, uid = 10306, app = org.workouthelper.workouthelper
06-15 22:16:39.371 2052 5221 I Timeline: Timeline: Activity_windows_visible id: ActivityRecord{18c71e u0 org.workouthelper.workouthelper/org.kivy.android.PythonActivity t9694} time:49848452
06-15 22:16:39.373 904 1349 E BufferQueueProducer: [SurfaceView - org.workouthelper.workouthelper/org.kivy.android.PythonActivity#0] query: BufferQueue has been abandoned
06-15 22:16:39.373 904 1349 E BufferQueueProducer: [SurfaceView - org.workouthelper.workouthelper/org.kivy.android.PythonActivity#0] dequeueBuffer: BufferQueue has been abandoned
06-15 22:16:39.373 904 1349 E BufferQueueProducer: [SurfaceView - org.workouthelper.workouthelper/org.kivy.android.PythonActivity#0] query: BufferQueue has been abandoned
06-15 22:16:39.373 904 1349 E BufferQueueProducer: [SurfaceView - org.workouthelper.workouthelper/org.kivy.android.PythonActivity#0] dequeueBuffer: BufferQueue has been abandoned
Weirdly enough the app goes back to normal after opening the notification tray and closing it again.
Version info
Any help on this would be greatly appreciated!
I described workaround for your problem here:
https://github.com/kivy/kivy/issues/6944#issuecomment-927382493
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.