mirror of
https://github.com/RYDE-WORK/ballistica.git
synced 2026-02-07 08:03:30 +08:00
pause/resume current activity
This commit is contained in:
parent
2ddb0d6eb4
commit
ea82263058
@ -133,8 +133,15 @@ class ContinuesWindow(ba.Window):
|
|||||||
ba.WeakCall(self._tick),
|
ba.WeakCall(self._tick),
|
||||||
repeat=True,
|
repeat=True,
|
||||||
timetype=ba.TimeType.REAL)
|
timetype=ba.TimeType.REAL)
|
||||||
|
|
||||||
|
# If there is foreground activity, suspend it.
|
||||||
|
ba.app.pause()
|
||||||
self._tick()
|
self._tick()
|
||||||
|
|
||||||
|
def __del__(self) -> None:
|
||||||
|
# If there is suspended foreground activity, resume it.
|
||||||
|
ba.app.resume()
|
||||||
|
|
||||||
def _tick(self) -> None:
|
def _tick(self) -> None:
|
||||||
# if our target activity is gone or has ended, go away
|
# if our target activity is gone or has ended, go away
|
||||||
activity = self._activity()
|
activity = self._activity()
|
||||||
|
|||||||
@ -236,7 +236,7 @@ class CreditsListWindow(ba.Window):
|
|||||||
'${NAME}', 'the Khronos Group') + '\n'
|
'${NAME}', 'the Khronos Group') + '\n'
|
||||||
'\n'
|
'\n'
|
||||||
' '
|
' '
|
||||||
' www.froemling.net\n')
|
' www.ballistica.net\n')
|
||||||
|
|
||||||
txt = credits_text
|
txt = credits_text
|
||||||
lines = txt.splitlines()
|
lines = txt.splitlines()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user