summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Thompson <daniel@redfelineninja.org.uk>2020-11-29 09:01:08 (GMT)
committerDaniel Thompson <daniel@redfelineninja.org.uk>2020-11-29 09:12:14 (GMT)
commitbcf616f7bc6dda3cb2bb2b92296b06cbdfbd7999 (patch)
treefe99da66fa13a31e2c497450cce8b6c067ab5beb
parent167173e9bac0776ebf91759d27a0333f90a7893b (diff)
apps: pager: notifications: fix handling of touch messages
Currently there are detailed hit boxes in the confirmation view widget but any inaccurate hit is treated as No anyway by the notification app. Additionally selecting 'No' dismisses the whole notification app rather than just the confirmation view. Fix the event handling so that we ignore touches outside the hit box and only dismiss the whole notification app if we actually clear the notifications. Signed-off-by: Daniel Thompson <daniel@redfelineninja.org.uk>
-rw-r--r--wasp/apps/pager.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/wasp/apps/pager.py b/wasp/apps/pager.py
index f33e9be..15b0bab 100644
--- a/wasp/apps/pager.py
+++ b/wasp/apps/pager.py
@@ -112,8 +112,9 @@ class NotificationApp(PagerApp):
is_confirmed = self.confirmation_view.touch(event)
if is_confirmed:
wasp.system.notifications = {}
- wasp.system.navigate(wasp.EventType.BACK)
- self.confirmation_view.active = False
+ wasp.system.navigate(wasp.EventType.BACK)
+ elif is_confirmed != None:
+ self._draw()
class CrashApp():