diff --git a/src/App/Pages/Settings/SettingsPage/SettingsPageViewModel.cs b/src/App/Pages/Settings/SettingsPage/SettingsPageViewModel.cs index 2cadfd63f..ce4ca3179 100644 --- a/src/App/Pages/Settings/SettingsPage/SettingsPageViewModel.cs +++ b/src/App/Pages/Settings/SettingsPage/SettingsPageViewModel.cs @@ -39,6 +39,7 @@ namespace Bit.App.Pages new KeyValuePair(AppResources.LockOption30Minutes, 30), new KeyValuePair(AppResources.LockOption1Hour, 60), new KeyValuePair(AppResources.LockOption4Hours, 240), + new KeyValuePair(AppResources.LockOptionOnRestart, -1), new KeyValuePair(AppResources.Never, null), }; diff --git a/src/App/Resources/AppResources.Designer.cs b/src/App/Resources/AppResources.Designer.cs index a6bd7d970..5384acb58 100644 --- a/src/App/Resources/AppResources.Designer.cs +++ b/src/App/Resources/AppResources.Designer.cs @@ -2256,6 +2256,24 @@ namespace Bit.App.Resources { } } + /// + /// Looks up a localized string similar to On Device Lock. + /// + public static string LockOptionOnDeviceLock { + get { + return ResourceManager.GetString("LockOptionOnDeviceLock", resourceCulture); + } + } + + /// + /// Looks up a localized string similar to On App Restart. + /// + public static string LockOptionOnRestart { + get { + return ResourceManager.GetString("LockOptionOnRestart", resourceCulture); + } + } + /// /// Looks up a localized string similar to Lock Options. /// diff --git a/src/App/Resources/AppResources.resx b/src/App/Resources/AppResources.resx index 3505b418a..e31c6b94a 100644 --- a/src/App/Resources/AppResources.resx +++ b/src/App/Resources/AppResources.resx @@ -1592,4 +1592,10 @@ The "Save Prompt" automatically prompts you to save new items to your vault whenever you enter them for the first time. + + On Device Lock + + + On App Restart + \ No newline at end of file diff --git a/src/App/Utilities/AppHelpers.cs b/src/App/Utilities/AppHelpers.cs index d66072e8e..466309a09 100644 --- a/src/App/Utilities/AppHelpers.cs +++ b/src/App/Utilities/AppHelpers.cs @@ -121,6 +121,7 @@ namespace Bit.App.Utilities if(lastBuild == null) { // Installed + await storageService.SaveAsync(Constants.LockOptionKey, -1); } else if(lastBuild != currentBuild) {