From 99c734e175a392012fab9bfb09c63b6ad1e21d07 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sim=C3=B3=20Albert=20i=20Beltran?= Date: Thu, 23 May 2024 10:30:24 +0200 Subject: [PATCH] Switch to Today Page after first sync MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Instead of remaining in Status Page with the message "Not Task Lists" Signed-off-by: Simó Albert i Beltran --- errands/lib/sync/sync.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/errands/lib/sync/sync.py b/errands/lib/sync/sync.py index 632cf2a7..c05b6b40 100644 --- a/errands/lib/sync/sync.py +++ b/errands/lib/sync/sync.py @@ -55,6 +55,11 @@ def sync(self) -> None: self.sync_again = False GLib.idle_add(State.sidebar.toggle_sync_indicator, False) self.syncing = False + if ( + State.view_stack.get_visible_child_name() == "errands_status_page" + and UserData.task_lists + ): + State.view_stack.set_visible_child_name("errands_today_page") # TODO: Needs to be threaded to not block UI @classmethod