diff --git a/src/KeePassLib2AndroidSdkStyle/Kp2aLog.cs b/src/KeePassLib2AndroidSdkStyle/Kp2aLog.cs index 2226ee87..93106e13 100644 --- a/src/KeePassLib2AndroidSdkStyle/Kp2aLog.cs +++ b/src/KeePassLib2AndroidSdkStyle/Kp2aLog.cs @@ -108,8 +108,12 @@ namespace keepass2android public static void SendLog(Context ctx) { - if (!File.Exists(LogFilename)) - return; + if (!File.Exists(LogFilename)) + { + Toast.MakeText(ctx, "Debug log is empty.", ToastLength.Long).Show(); + return; + } + Intent sendIntent = new Intent(); sendIntent.SetAction(Intent.ActionSend); sendIntent.PutExtra(Intent.ExtraText, File.ReadAllText(LogFilename)); diff --git a/src/keepass2android-appSdkStyle/AboutActivity.cs b/src/keepass2android-appSdkStyle/AboutActivity.cs index e0a8cf3e..5958a3e8 100644 --- a/src/keepass2android-appSdkStyle/AboutActivity.cs +++ b/src/keepass2android-appSdkStyle/AboutActivity.cs @@ -10,7 +10,7 @@ namespace keepass2android { [Activity(Label = "@string/app_name", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.KeyboardHidden, - Theme = "@style/MyTheme_ActionBar", + Theme = "@style/Kp2aTheme_ActionBar", Exported = true)] [IntentFilter(new[] { "kp2a.action.AboutActivity" }, Categories = new[] { Intent.CategoryDefault })] public class AboutActivity: Activity, IDialogInterfaceOnDismissListener diff --git a/src/keepass2android-appSdkStyle/CloseImmediatelyActivity.cs b/src/keepass2android-appSdkStyle/CloseImmediatelyActivity.cs index 5813f45a..9d525518 100644 --- a/src/keepass2android-appSdkStyle/CloseImmediatelyActivity.cs +++ b/src/keepass2android-appSdkStyle/CloseImmediatelyActivity.cs @@ -14,7 +14,7 @@ using keepass2android_appSdkStyle; namespace keepass2android { - [Activity(Label = AppNames.AppName, Theme = "@style/MyTheme_ActionBar", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden)] + [Activity(Label = AppNames.AppName, Theme = "@style/Kp2aTheme_ActionBar", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden)] public class CloseImmediatelyActivity : AndroidX.AppCompat.App.AppCompatActivity { protected override void OnResume() diff --git a/src/keepass2android-appSdkStyle/ConfigureChildDatabasesActivity.cs b/src/keepass2android-appSdkStyle/ConfigureChildDatabasesActivity.cs index 3d2f334d..e76a02ef 100644 --- a/src/keepass2android-appSdkStyle/ConfigureChildDatabasesActivity.cs +++ b/src/keepass2android-appSdkStyle/ConfigureChildDatabasesActivity.cs @@ -28,7 +28,7 @@ using Object = Java.Lang.Object; namespace keepass2android { - [Activity(Label = "@string/child_dbs_title", MainLauncher = false, Theme = "@style/MyTheme_Blue", LaunchMode = LaunchMode.SingleInstance, ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden, Exported = true)] + [Activity(Label = "@string/child_dbs_title", MainLauncher = false, Theme = "@style/Kp2aTheme_BlueNoActionBar", LaunchMode = LaunchMode.SingleInstance, ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden, Exported = true)] [IntentFilter(new[] { "kp2a.action.ConfigureChildDatabasesActivity" }, Categories = new[] { Intent.CategoryDefault })] public class ConfigureChildDatabasesActivity : LockCloseActivity { diff --git a/src/keepass2android-appSdkStyle/CreateDatabaseActivity.cs b/src/keepass2android-appSdkStyle/CreateDatabaseActivity.cs index ec7a4586..ae24abee 100644 --- a/src/keepass2android-appSdkStyle/CreateDatabaseActivity.cs +++ b/src/keepass2android-appSdkStyle/CreateDatabaseActivity.cs @@ -20,7 +20,7 @@ namespace keepass2android { [Activity(Label = "@string/app_name", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.KeyboardHidden, - Theme = "@style/MyTheme_ActionBar")] + Theme = "@style/Kp2aTheme_ActionBar")] public class CreateDatabaseActivity : LifecycleAwareActivity { private IOConnectionInfo _ioc; diff --git a/src/keepass2android-appSdkStyle/DonateReminder.cs b/src/keepass2android-appSdkStyle/DonateReminder.cs index ddb43347..68236543 100644 --- a/src/keepass2android-appSdkStyle/DonateReminder.cs +++ b/src/keepass2android-appSdkStyle/DonateReminder.cs @@ -15,7 +15,7 @@ using KeePassLib.Utility; namespace keepass2android { - [Activity(Label = AppNames.AppName, Theme = "@style/MyTheme_ActionBar")] + [Activity(Label = AppNames.AppName, Theme = "@style/Kp2aTheme_ActionBar")] public class DonateReminder : Activity { class Reminder diff --git a/src/keepass2android-appSdkStyle/EntryActivity.cs b/src/keepass2android-appSdkStyle/EntryActivity.cs index d97ddf96..27f2114c 100644 --- a/src/keepass2android-appSdkStyle/EntryActivity.cs +++ b/src/keepass2android-appSdkStyle/EntryActivity.cs @@ -94,7 +94,7 @@ namespace keepass2android [Activity (Label = "@string/app_name", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden, - Theme = "@style/MyTheme_ActionBar")] + Theme = "@style/Kp2aTheme_ActionBar")] public class EntryActivity : LockCloseActivity { public const String KeyEntry = "entry"; diff --git a/src/keepass2android-appSdkStyle/EntryEditActivity.cs b/src/keepass2android-appSdkStyle/EntryEditActivity.cs index 0a479e13..1c38ed65 100644 --- a/src/keepass2android-appSdkStyle/EntryEditActivity.cs +++ b/src/keepass2android-appSdkStyle/EntryEditActivity.cs @@ -54,7 +54,7 @@ using Resource = keepass2android_appSdkStyle.Resource; namespace keepass2android { - [Activity(Label = "@string/app_name", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden, Theme = "@style/MyTheme_ActionBar")] + [Activity(Label = "@string/app_name", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden, Theme = "@style/Kp2aTheme_ActionBar")] public class EntryEditActivity : LockCloseActivity { diff --git a/src/keepass2android-appSdkStyle/ExportDatabaseActivity.cs b/src/keepass2android-appSdkStyle/ExportDatabaseActivity.cs index 5d8bbdda..1799ca08 100644 --- a/src/keepass2android-appSdkStyle/ExportDatabaseActivity.cs +++ b/src/keepass2android-appSdkStyle/ExportDatabaseActivity.cs @@ -42,7 +42,7 @@ namespace keepass2android [Activity(Label = "@string/app_name", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden, - Theme = "@style/MyTheme_ActionBar", Exported = true)] + Theme = "@style/Kp2aTheme_ActionBar", Exported = true)] [IntentFilter(new[] {"kp2a.action.ExportDatabaseActivity"}, Categories = new[] {Intent.CategoryDefault})] public class ExportDatabaseActivity : LockCloseActivity { diff --git a/src/keepass2android-appSdkStyle/FileStorageSelectionActivity.cs b/src/keepass2android-appSdkStyle/FileStorageSelectionActivity.cs index 7b4fe1c5..887879a9 100644 --- a/src/keepass2android-appSdkStyle/FileStorageSelectionActivity.cs +++ b/src/keepass2android-appSdkStyle/FileStorageSelectionActivity.cs @@ -21,7 +21,7 @@ using Resource = keepass2android_appSdkStyle.Resource; namespace keepass2android { - [Activity(Label = "@string/app_name", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.KeyboardHidden, Theme = "@style/MyTheme_Blue")] + [Activity(Label = "@string/app_name", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.KeyboardHidden, Theme = "@style/Kp2aTheme_BlueNoActionBar")] public class FileStorageSelectionActivity : AndroidX.AppCompat.App.AppCompatActivity { private readonly ActivityDesign _design; diff --git a/src/keepass2android-appSdkStyle/FingerprintSetupActivity.cs b/src/keepass2android-appSdkStyle/FingerprintSetupActivity.cs index 9be65932..9d1d1c6b 100644 --- a/src/keepass2android-appSdkStyle/FingerprintSetupActivity.cs +++ b/src/keepass2android-appSdkStyle/FingerprintSetupActivity.cs @@ -23,7 +23,7 @@ namespace keepass2android { [Activity(Label = "@string/app_name", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden, - Theme = "@style/MyTheme_ActionBar", MainLauncher = false, Exported = true)] + Theme = "@style/Kp2aTheme_ActionBar", MainLauncher = false, Exported = true)] [IntentFilter(new[] { "kp2a.action.FingerprintSetupActivity" }, Categories = new[] { Intent.CategoryDefault })] public class BiometricSetupActivity : LockCloseActivity, IBiometricAuthCallback { @@ -269,7 +269,7 @@ namespace keepass2android _fpTextView.RemoveCallbacks(ResetErrorTextRunnable); _fpIcon.SetImageResource(Resource.Drawable.ic_fingerprint_success); - _fpTextView.SetTextColor(_fpTextView.Resources.GetColor(Resource.Color.success_color, null)); + _fpTextView.SetTextColor(_fpTextView.Resources.GetColor(Resource.Color.md_theme_secondary, null)); _fpTextView.Text = _fpTextView.Resources.GetString(Resource.String.fingerprint_success); _fpIcon.PostDelayed(() => { @@ -292,7 +292,7 @@ namespace keepass2android _fpIcon.SetImageResource(Resource.Drawable.ic_fingerprint_error); _fpTextView.Text = error; _fpTextView.SetTextColor( - _fpTextView.Resources.GetColor(Resource.Color.warning_color, null)); + _fpTextView.Resources.GetColor(Resource.Color.md_theme_error, null)); _fpTextView.RemoveCallbacks(ResetErrorTextRunnable); _fpTextView.PostDelayed(ResetErrorTextRunnable, ERROR_TIMEOUT_MILLIS); } @@ -305,7 +305,7 @@ namespace keepass2android void ResetErrorTextRunnable() { _fpTextView.SetTextColor( - _fpTextView.Resources.GetColor(Resource.Color.hint_color, null)); + _fpTextView.Resources.GetColor(Resource.Color.md_theme_secondary, null)); _fpTextView.Text = ""; _fpIcon.SetImageResource(Resource.Drawable.ic_fp_40px); } diff --git a/src/keepass2android-appSdkStyle/GeneratePasswordActivity.cs b/src/keepass2android-appSdkStyle/GeneratePasswordActivity.cs index 63979542..b54910ff 100644 --- a/src/keepass2android-appSdkStyle/GeneratePasswordActivity.cs +++ b/src/keepass2android-appSdkStyle/GeneratePasswordActivity.cs @@ -36,7 +36,7 @@ using OtpKeyProv; namespace keepass2android { - [Activity(Label = "@string/app_name", Theme = "@style/MyTheme_ActionBar", WindowSoftInputMode = SoftInput.StateHidden, ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden)] + [Activity(Label = "@string/app_name", Theme = "@style/Kp2aTheme_ActionBar", WindowSoftInputMode = SoftInput.StateHidden, ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden)] public class GeneratePasswordActivity : #if DEBUG LifecycleAwareActivity diff --git a/src/keepass2android-appSdkStyle/GroupActivity.cs b/src/keepass2android-appSdkStyle/GroupActivity.cs index d2b8acf5..68d7bb61 100644 --- a/src/keepass2android-appSdkStyle/GroupActivity.cs +++ b/src/keepass2android-appSdkStyle/GroupActivity.cs @@ -41,7 +41,7 @@ using Object = Java.Lang.Object; namespace keepass2android { - [Activity(Label = "@string/app_name", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden, Theme = "@style/MyTheme_ActionBar", Exported = true)] + [Activity(Label = "@string/app_name", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden, Theme = "@style/Kp2aTheme_ActionBar", Exported = true)] [MetaData("android.app.default_searchable", Value = "keepass2android.search.SearchResults")] #if NoNet [MetaData("android.app.searchable", Resource = "@xml/searchable_offline")] diff --git a/src/keepass2android-appSdkStyle/GroupBaseActivity.cs b/src/keepass2android-appSdkStyle/GroupBaseActivity.cs index 41e54da7..5763fb1c 100644 --- a/src/keepass2android-appSdkStyle/GroupBaseActivity.cs +++ b/src/keepass2android-appSdkStyle/GroupBaseActivity.cs @@ -299,7 +299,7 @@ namespace keepass2android { RunOnUiThread(() => { - var listView = FragmentManager.FindFragmentById(Resource.Id.list_fragment) + var listView = FragmentManager?.FindFragmentById(Resource.Id.list_fragment) .ListView; if (listView != null) { @@ -1351,6 +1351,7 @@ namespace keepass2android FindViewById(Resource.Id.fabAddNewEntry).Visibility = ViewStates.Gone; FindViewById(Resource.Id.fabAddNew).Visibility = ViewStates.Gone; FindViewById(Resource.Id.fabSearch).Visibility = ViewStates.Gone; + FindViewById(Resource.Id.fabTotpOverview).Visibility = ViewStates.Gone; UpdateBottomBarElementVisibility(Resource.Id.insert_element, true); UpdateBottomBarElementVisibility(Resource.Id.cancel_insert_element, true); @@ -1500,7 +1501,7 @@ namespace keepass2android if (Build.VERSION.SdkInt >= BuildVersionCodes.Lollipop) { _statusBarColor = Activity.Window.StatusBarColor; - Activity.Window.SetStatusBarColor(Activity.Resources.GetColor(Resource.Color.appAccentColorDark)); + Activity.Window.SetStatusBarColor(Activity.Resources.GetColor(Resource.Color.md_theme_secondary)); } return true; } diff --git a/src/keepass2android-appSdkStyle/GroupEditActivity.cs b/src/keepass2android-appSdkStyle/GroupEditActivity.cs index 0909019e..d3703e89 100644 --- a/src/keepass2android-appSdkStyle/GroupEditActivity.cs +++ b/src/keepass2android-appSdkStyle/GroupEditActivity.cs @@ -27,7 +27,7 @@ using KeePassLib.Utility; namespace keepass2android { - [Activity(Label = "@string/app_name", Theme = "@style/Dialog")] + [Activity(Label = "@string/app_name")] public class GroupEditActivity : LifecycleAwareActivity { public const String KeyParent = "parent"; diff --git a/src/keepass2android-appSdkStyle/IconPickerActivity.cs b/src/keepass2android-appSdkStyle/IconPickerActivity.cs index 5c99dcfb..23a6b02e 100644 --- a/src/keepass2android-appSdkStyle/IconPickerActivity.cs +++ b/src/keepass2android-appSdkStyle/IconPickerActivity.cs @@ -35,7 +35,7 @@ using IOException = Java.IO.IOException; namespace keepass2android { - [Activity(Label = "@string/app_name", Theme = "@style/MyTheme_ActionBar", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden)] + [Activity(Label = "@string/app_name", Theme = "@style/Kp2aTheme_ActionBar", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden)] public class IconPickerActivity : LockCloseActivity { public const string KeyIconId = "icon_id"; diff --git a/src/keepass2android-appSdkStyle/ImageViewActivity.cs b/src/keepass2android-appSdkStyle/ImageViewActivity.cs index 79ce7460..b9c088f6 100644 --- a/src/keepass2android-appSdkStyle/ImageViewActivity.cs +++ b/src/keepass2android-appSdkStyle/ImageViewActivity.cs @@ -295,7 +295,7 @@ namespace keepass2android } } [Activity(Label = "@string/app_name", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden, - Theme = "@style/MyTheme_ActionBar")] + Theme = "@style/Kp2aTheme_ActionBar")] public class ImageViewActivity : LockCloseActivity { private ActivityDesign _activityDesign; diff --git a/src/keepass2android-appSdkStyle/KeePass.cs b/src/keepass2android-appSdkStyle/KeePass.cs index 984c7c75..b74bd5af 100644 --- a/src/keepass2android-appSdkStyle/KeePass.cs +++ b/src/keepass2android-appSdkStyle/KeePass.cs @@ -69,7 +69,7 @@ namespace keepass2android /// /// Launcher activity of Keepass2Android. This activity usually forwards to SelectCurrentDb but may show the revision dialog after installation or updates. /// - [Activity(Label = AppNames.AppName, MainLauncher = false, Theme = "@style/MyTheme_Blue", Exported = true)] + [Activity(Label = AppNames.AppName, MainLauncher = false, Theme = "@style/Kp2aTheme_BlueActionBar", Exported = true)] [IntentFilter(new[] { Intent.ActionMain }, Categories = new[] { "android.intent.category.LAUNCHER", "android.intent.category.MULTIWINDOW_LAUNCHER" })] public class KeePass : LifecycleAwareActivity, IDialogInterfaceOnDismissListener { diff --git a/src/keepass2android-appSdkStyle/Manifests/AndroidManifest_debug.xml b/src/keepass2android-appSdkStyle/Manifests/AndroidManifest_debug.xml index f2475c55..22d4e019 100644 --- a/src/keepass2android-appSdkStyle/Manifests/AndroidManifest_debug.xml +++ b/src/keepass2android-appSdkStyle/Manifests/AndroidManifest_debug.xml @@ -108,7 +108,7 @@ - + diff --git a/src/keepass2android-appSdkStyle/Manifests/AndroidManifest_net.xml b/src/keepass2android-appSdkStyle/Manifests/AndroidManifest_net.xml index 97bbcc38..812fadf1 100644 --- a/src/keepass2android-appSdkStyle/Manifests/AndroidManifest_net.xml +++ b/src/keepass2android-appSdkStyle/Manifests/AndroidManifest_net.xml @@ -112,7 +112,7 @@ - + diff --git a/src/keepass2android-appSdkStyle/Manifests/AndroidManifest_nonet.xml b/src/keepass2android-appSdkStyle/Manifests/AndroidManifest_nonet.xml index 6ef986aa..ce9e2f9c 100644 --- a/src/keepass2android-appSdkStyle/Manifests/AndroidManifest_nonet.xml +++ b/src/keepass2android-appSdkStyle/Manifests/AndroidManifest_nonet.xml @@ -82,7 +82,7 @@ - diff --git a/src/keepass2android-appSdkStyle/NoSecureDisplayActivity.cs b/src/keepass2android-appSdkStyle/NoSecureDisplayActivity.cs index bc4beeef..9188cda9 100644 --- a/src/keepass2android-appSdkStyle/NoSecureDisplayActivity.cs +++ b/src/keepass2android-appSdkStyle/NoSecureDisplayActivity.cs @@ -15,7 +15,7 @@ using keepass2android_appSdkStyle; namespace keepass2android { - [Activity(Label = AppNames.AppName, ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.KeyboardHidden, Theme = "@style/MyTheme_Blue", + [Activity(Label = AppNames.AppName, ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.KeyboardHidden, Theme = "@style/Kp2aTheme_BlueActionBar", LaunchMode = LaunchMode.SingleInstance)] public class NoSecureDisplayActivity : AndroidX.AppCompat.App.AppCompatActivity { diff --git a/src/keepass2android-appSdkStyle/PasswordActivity.cs b/src/keepass2android-appSdkStyle/PasswordActivity.cs index dbdcb622..f92d1af6 100644 --- a/src/keepass2android-appSdkStyle/PasswordActivity.cs +++ b/src/keepass2android-appSdkStyle/PasswordActivity.cs @@ -63,6 +63,7 @@ using ClipboardManager = Android.Content.ClipboardManager; using Enum = System.Enum; using Exception = System.Exception; using String = System.String; +using Toolbar = AndroidX.AppCompat.Widget.Toolbar; namespace keepass2android { @@ -70,7 +71,7 @@ namespace keepass2android ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.Keyboard | ConfigChanges.KeyboardHidden, LaunchMode = LaunchMode.SingleInstance, WindowSoftInputMode = SoftInput.AdjustResize, - Theme = "@style/MyTheme_Blue")] + Theme = "@style/Kp2aTheme_BlueNoActionBar")] public class PasswordActivity : LockingActivity, IBiometricAuthCallback { @@ -1048,9 +1049,7 @@ namespace keepass2android private void InitializeToolbar() { - var toolbar = FindViewById(Resource.Id.mytoolbar); - - SetSupportActionBar(toolbar); + var collapsingToolbar = FindViewById(Resource.Id.collapsing_toolbar); collapsingToolbar.SetTitle(GetString(Resource.String.unlock_database_title)); @@ -1063,7 +1062,7 @@ namespace keepass2android _drawerLayout?.SetDrawerListener(mDrawerToggle); - + SetSupportActionBar(FindViewById(Resource.Id.toolbar)); SupportActionBar.SetDisplayHomeAsUpEnabled(true); SupportActionBar.SetHomeButtonEnabled(true); mDrawerToggle.SyncState(); @@ -2008,7 +2007,7 @@ namespace keepass2android { Kp2aLog.LogUnexpectedError(e); } - SetEditText(Resource.Id.filename, filenameToShow); + //SetEditText(Resource.Id.filename, filenameToShow); } diff --git a/src/keepass2android-appSdkStyle/QueryCredentialsActivity.cs b/src/keepass2android-appSdkStyle/QueryCredentialsActivity.cs index 25462a5b..80fc9fd5 100644 --- a/src/keepass2android-appSdkStyle/QueryCredentialsActivity.cs +++ b/src/keepass2android-appSdkStyle/QueryCredentialsActivity.cs @@ -18,7 +18,7 @@ namespace keepass2android [Activity(Label = "@string/app_name", ConfigurationChanges = ConfigChanges.Orientation | ConfigChanges.KeyboardHidden, Exported = true, - Theme = "@style/MyTheme_ActionBar")] + Theme = "@style/Kp2aTheme_ActionBar")] [IntentFilter(new[] { Strings.ActionQueryCredentials}, Categories = new[] { Intent.CategoryDefault })] [IntentFilter(new[] { Strings.ActionQueryCredentialsForOwnPackage }, diff --git a/src/keepass2android-appSdkStyle/QuickUnlock.cs b/src/keepass2android-appSdkStyle/QuickUnlock.cs index 1acb7bb6..81037efd 100644 --- a/src/keepass2android-appSdkStyle/QuickUnlock.cs +++ b/src/keepass2android-appSdkStyle/QuickUnlock.cs @@ -32,6 +32,7 @@ using Google.Android.Material.AppBar; using keepass2android_appSdkStyle; using KeePassLib; using KeePassLib.Serialization; +using Toolbar = AndroidX.AppCompat.Widget.Toolbar; namespace keepass2android { @@ -39,7 +40,7 @@ namespace keepass2android ConfigurationChanges = ConfigChanges.Orientation, WindowSoftInputMode = SoftInput.AdjustResize, MainLauncher = false, - Theme = "@style/MyTheme_Blue")] + Theme = "@style/Kp2aTheme_BlueNoActionBar")] public class QuickUnlock : LifecycleAwareActivity, IBiometricAuthCallback { private IOConnectionInfo _ioc; @@ -76,14 +77,12 @@ namespace keepass2android SetContentView(Resource.Layout.QuickUnlock); - var toolbar = FindViewById(Resource.Id.mytoolbar); - - SetSupportActionBar(toolbar); var collapsingToolbar = FindViewById(Resource.Id.collapsing_toolbar); collapsingToolbar.SetTitle(GetString(Resource.String.QuickUnlock_prefs)); - - if (App.Kp2a.GetDbForQuickUnlock().KpDatabase.Name != "") + SetSupportActionBar(FindViewById(Resource.Id.toolbar)); + + if (App.Kp2a.GetDbForQuickUnlock().KpDatabase.Name != "") { FindViewById(Resource.Id.filename_label).Visibility = ViewStates.Visible; ((TextView) FindViewById(Resource.Id.filename_label)).Text = App.Kp2a.GetDbForQuickUnlock().KpDatabase.Name; diff --git a/src/keepass2android-appSdkStyle/Resources/drawable-mdpi/toolbar_bg.png b/src/keepass2android-appSdkStyle/Resources/drawable-mdpi/toolbar_bg.png index d46f91c8..5fc642ca 100644 Binary files a/src/keepass2android-appSdkStyle/Resources/drawable-mdpi/toolbar_bg.png and b/src/keepass2android-appSdkStyle/Resources/drawable-mdpi/toolbar_bg.png differ diff --git a/src/keepass2android-appSdkStyle/Resources/drawable-mdpi/toolbar_bg_quickunlock.png b/src/keepass2android-appSdkStyle/Resources/drawable-mdpi/toolbar_bg_quickunlock.png index 04cb0623..77392218 100644 Binary files a/src/keepass2android-appSdkStyle/Resources/drawable-mdpi/toolbar_bg_quickunlock.png and b/src/keepass2android-appSdkStyle/Resources/drawable-mdpi/toolbar_bg_quickunlock.png differ diff --git a/src/keepass2android-appSdkStyle/Resources/drawable-night-mdpi/splashlogo.png b/src/keepass2android-appSdkStyle/Resources/drawable-night-mdpi/splashlogo.png new file mode 100644 index 00000000..e0f475a0 Binary files /dev/null and b/src/keepass2android-appSdkStyle/Resources/drawable-night-mdpi/splashlogo.png differ diff --git a/src/keepass2android-appSdkStyle/Resources/drawable-night-xhdpi/splashlogo.png b/src/keepass2android-appSdkStyle/Resources/drawable-night-xhdpi/splashlogo.png new file mode 100644 index 00000000..20836ae0 Binary files /dev/null and b/src/keepass2android-appSdkStyle/Resources/drawable-night-xhdpi/splashlogo.png differ diff --git a/src/keepass2android-appSdkStyle/Resources/drawable-night-xhdpi/toolbar_bg.png b/src/keepass2android-appSdkStyle/Resources/drawable-night-xhdpi/toolbar_bg.png new file mode 100644 index 00000000..65f3d976 Binary files /dev/null and b/src/keepass2android-appSdkStyle/Resources/drawable-night-xhdpi/toolbar_bg.png differ diff --git a/src/keepass2android-appSdkStyle/Resources/drawable-night-xhdpi/toolbar_bg_quickunlock.png b/src/keepass2android-appSdkStyle/Resources/drawable-night-xhdpi/toolbar_bg_quickunlock.png new file mode 100644 index 00000000..18834e3f Binary files /dev/null and b/src/keepass2android-appSdkStyle/Resources/drawable-night-xhdpi/toolbar_bg_quickunlock.png differ diff --git a/src/keepass2android-appSdkStyle/Resources/drawable-xhdpi/toolbar_bg.png b/src/keepass2android-appSdkStyle/Resources/drawable-xhdpi/toolbar_bg.png index d695f1ca..75a58f1d 100644 Binary files a/src/keepass2android-appSdkStyle/Resources/drawable-xhdpi/toolbar_bg.png and b/src/keepass2android-appSdkStyle/Resources/drawable-xhdpi/toolbar_bg.png differ diff --git a/src/keepass2android-appSdkStyle/Resources/drawable-xhdpi/toolbar_bg_quickunlock.png b/src/keepass2android-appSdkStyle/Resources/drawable-xhdpi/toolbar_bg_quickunlock.png index 8d06cc41..41f816e0 100644 Binary files a/src/keepass2android-appSdkStyle/Resources/drawable-xhdpi/toolbar_bg_quickunlock.png and b/src/keepass2android-appSdkStyle/Resources/drawable-xhdpi/toolbar_bg_quickunlock.png differ diff --git a/src/keepass2android-appSdkStyle/Resources/drawable/extra_string_header.xml b/src/keepass2android-appSdkStyle/Resources/drawable/extra_string_header.xml index 841b8815..5c556ade 100644 --- a/src/keepass2android-appSdkStyle/Resources/drawable/extra_string_header.xml +++ b/src/keepass2android-appSdkStyle/Resources/drawable/extra_string_header.xml @@ -4,5 +4,5 @@ android:shape="rectangle"> + android:color="@color/md_theme_secondary"/> \ No newline at end of file diff --git a/src/keepass2android-appSdkStyle/Resources/drawable/section_header.xml b/src/keepass2android-appSdkStyle/Resources/drawable/section_header.xml index fbe5fae4..8fb9d921 100644 --- a/src/keepass2android-appSdkStyle/Resources/drawable/section_header.xml +++ b/src/keepass2android-appSdkStyle/Resources/drawable/section_header.xml @@ -4,5 +4,5 @@ android:shape="rectangle"> + android:color="@color/md_theme_surface"/> \ No newline at end of file diff --git a/src/keepass2android-appSdkStyle/Resources/layout-land/file_selection.xml b/src/keepass2android-appSdkStyle/Resources/layout-land/file_selection.xml index 96c63077..70017587 100644 --- a/src/keepass2android-appSdkStyle/Resources/layout-land/file_selection.xml +++ b/src/keepass2android-appSdkStyle/Resources/layout-land/file_selection.xml @@ -1,87 +1,120 @@ - - - - - - - - - + + + - + android:layout_height="fill_parent" + android:paddingLeft="32dp" + android:paddingRight="32dp" + android:gravity="center_horizontal" + android:fitsSystemWindows="true"> + -