From 6d50b1f1f5d52a751795101b87fc5d0105c48a4f Mon Sep 17 00:00:00 2001 From: Mathieu Pellerin Date: Fri, 5 Jan 2024 09:28:41 +0700 Subject: [PATCH 1/2] Set default packaging toolbar visibility preference to true --- qfieldsync/core/preferences.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qfieldsync/core/preferences.py b/qfieldsync/core/preferences.py index cfec8de8..a17b8dec 100644 --- a/qfieldsync/core/preferences.py +++ b/qfieldsync/core/preferences.py @@ -23,7 +23,7 @@ def __init__(self): self.add_setting( String("importDirectory", Scope.Global, str(home.joinpath("QField/import"))) ) - self.add_setting(Bool("showPackagingActions", Scope.Global, False)) + self.add_setting(Bool("showPackagingActions", Scope.Global, True)) self.add_setting(String("importDirectoryProject", Scope.Project, None)) self.add_setting(Dictionary("dirsToCopy", Scope.Project, {})) self.add_setting(Stringlist("attachmentDirs", Scope.Project, ["DCIM"])) From 09b343a5dcfc31a8c30341fa212bd8f7ecb7f053 Mon Sep 17 00:00:00 2001 From: Mathieu Pellerin Date: Fri, 5 Jan 2024 09:43:01 +0700 Subject: [PATCH 2/2] Add first run check --- qfieldsync/core/preferences.py | 1 + qfieldsync/qfield_sync.py | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/qfieldsync/core/preferences.py b/qfieldsync/core/preferences.py index a17b8dec..a823617e 100644 --- a/qfieldsync/core/preferences.py +++ b/qfieldsync/core/preferences.py @@ -35,3 +35,4 @@ def __init__(self): self.add_setting( String("cloudDirectory", Scope.Global, str(home.joinpath("QField/cloud"))) ) + self.add_setting(Bool("firstRun", Scope.Global, True)) diff --git a/qfieldsync/qfield_sync.py b/qfieldsync/qfield_sync.py index f4c7d1df..8a748d50 100644 --- a/qfieldsync/qfield_sync.py +++ b/qfieldsync/qfield_sync.py @@ -146,7 +146,11 @@ def __init__(self, iface): self.cloud_item_gui_provider ) - # autologin + # first run check + if self.preferences.value("firstRun"): + self.preferences.set_value("firstRun", False) + + # auto login check if self.preferences.value("qfieldCloudRememberMe"): self.network_manager.auto_login_attempt()