diff options
Diffstat (limited to 'wasp/apps/pager.py')
| -rw-r--r-- | wasp/apps/pager.py | 17 |
1 files changed, 4 insertions, 13 deletions
diff --git a/wasp/apps/pager.py b/wasp/apps/pager.py index 2f74d0e..4f518eb 100644 --- a/wasp/apps/pager.py +++ b/wasp/apps/pager.py @@ -106,28 +106,19 @@ class NotificationApp(PagerApp): return else: if event[0] == wasp.EventType.DOWN and self._page == 0: - self.confirmation_view.active = True - self._draw() + self.confirmation_view.draw('Clear notifications?') return super().swipe(event) - def _draw(self): - if self.confirmation_view.active: - self.confirmation_view.draw('Clear notifications?') - else: - super()._draw() - def touch(self, event): - if self.confirmation_view.active: - is_confirmed = self.confirmation_view.touch(event) - if is_confirmed: + if self.confirmation_view.touch(event): + if self.confirmation_view.value: wasp.system.notifications = {} wasp.system.navigate(wasp.EventType.BACK) - elif is_confirmed != None: + else: self._draw() - class CrashApp(): """Crash handler application. |
