diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ea60139b..333e6b97 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -339,7 +339,7 @@ jobs: with: name: archive APK ('net' built on ${{ github.job }}) path: | - src/keepass2android-app/bin/Release/net8.0-android/publish/*.apk + src/keepass2android-app/bin/Release/net9.0-android/publish/*.apk - name: Select the manifest run: | @@ -365,5 +365,5 @@ jobs: with: name: archive APK ('nonet' built on ${{ github.job }}) path: | - src/keepass2android-app/bin/Release/net8.0-android/publish/*.apk + src/keepass2android-app/bin/Release/net9.0-android/publish/*.apk diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index e2866a43..e5ca3589 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -130,8 +130,8 @@ jobs: name: keepass2android_${{ matrix.target }}_${{ matrix.flavor }} # the first line is for "apk" target, the second line is for "apk_split" target path: | - src/keepass2android-app/bin/Release/net8.0-android/publish/*.apk - src/keepass2android-app/bin/Release/net8.0-android/*/publish/*.apk + src/keepass2android-app/bin/Release/net9.0-android/publish/*.apk + src/keepass2android-app/bin/Release/net9.0-android/*/publish/*.apk - name: List apks run: find . -type f -name "*.apk" @@ -142,5 +142,5 @@ jobs: with: draft: true files: | - src/keepass2android-app/bin/Release/net8.0-android/publish/*.apk - src/keepass2android-app/bin/Release/net8.0-android/*/publish/*.apk + src/keepass2android-app/bin/Release/net9.0-android/publish/*.apk + src/keepass2android-app/bin/Release/net9.0-android/*/publish/*.apk diff --git a/src/AndroidFileChooserBinding/AndroidFileChooserBinding.csproj b/src/AndroidFileChooserBinding/AndroidFileChooserBinding.csproj index c7147177..05e75e1a 100644 --- a/src/AndroidFileChooserBinding/AndroidFileChooserBinding.csproj +++ b/src/AndroidFileChooserBinding/AndroidFileChooserBinding.csproj @@ -1,6 +1,6 @@ - net8.0-android + net9.0-android 21 enable enable diff --git a/src/DropboxBinding/DropboxBinding.csproj b/src/DropboxBinding/DropboxBinding.csproj index f7a94a3c..2a14b6bf 100644 --- a/src/DropboxBinding/DropboxBinding.csproj +++ b/src/DropboxBinding/DropboxBinding.csproj @@ -1,6 +1,6 @@ - net8.0-android + net9.0-android 21 enable enable diff --git a/src/JavaFileStorageBindings/JavaFileStorageBindings.csproj b/src/JavaFileStorageBindings/JavaFileStorageBindings.csproj index e29888f6..7ffd0d17 100644 --- a/src/JavaFileStorageBindings/JavaFileStorageBindings.csproj +++ b/src/JavaFileStorageBindings/JavaFileStorageBindings.csproj @@ -1,6 +1,6 @@  - net8.0-android + net9.0-android 21 enable enable diff --git a/src/KP2AKdbLibraryBinding/KP2AKdbLibraryBinding.csproj b/src/KP2AKdbLibraryBinding/KP2AKdbLibraryBinding.csproj index d39c9b67..9aad4ee6 100644 --- a/src/KP2AKdbLibraryBinding/KP2AKdbLibraryBinding.csproj +++ b/src/KP2AKdbLibraryBinding/KP2AKdbLibraryBinding.csproj @@ -1,6 +1,6 @@  - net8.0-android + net9.0-android 21 enable enable diff --git a/src/KeePassLib2Android/KeePassLib2Android.csproj b/src/KeePassLib2Android/KeePassLib2Android.csproj index 17b69210..c5a8616a 100644 --- a/src/KeePassLib2Android/KeePassLib2Android.csproj +++ b/src/KeePassLib2Android/KeePassLib2Android.csproj @@ -1,6 +1,6 @@ - net8.0-android + net9.0-android 21 enable enable diff --git a/src/Kp2aBusinessLogic/Kp2aBusinessLogic.csproj b/src/Kp2aBusinessLogic/Kp2aBusinessLogic.csproj index 4f994cea..de807952 100644 --- a/src/Kp2aBusinessLogic/Kp2aBusinessLogic.csproj +++ b/src/Kp2aBusinessLogic/Kp2aBusinessLogic.csproj @@ -1,6 +1,6 @@  - net8.0-android + net9.0-android 21 enable enable diff --git a/src/Kp2aKeyboardBinding/Kp2aKeyboardBinding.csproj b/src/Kp2aKeyboardBinding/Kp2aKeyboardBinding.csproj index 696dc506..8be3c179 100644 --- a/src/Kp2aKeyboardBinding/Kp2aKeyboardBinding.csproj +++ b/src/Kp2aKeyboardBinding/Kp2aKeyboardBinding.csproj @@ -1,6 +1,6 @@  - net8.0-android + net9.0-android 21 enable enable diff --git a/src/PCloudBindings/PCloudBindings.csproj b/src/PCloudBindings/PCloudBindings.csproj index 495b27a6..2334a1a1 100644 --- a/src/PCloudBindings/PCloudBindings.csproj +++ b/src/PCloudBindings/PCloudBindings.csproj @@ -1,6 +1,6 @@ - net8.0-android + net9.0-android 21 enable enable diff --git a/src/PluginSdkBinding/PluginSdkBinding.csproj b/src/PluginSdkBinding/PluginSdkBinding.csproj index 16be7749..5e29f7c9 100644 --- a/src/PluginSdkBinding/PluginSdkBinding.csproj +++ b/src/PluginSdkBinding/PluginSdkBinding.csproj @@ -1,6 +1,6 @@  - net8.0-android + net9.0-android 21 enable enable diff --git a/src/TwofishCipher/TwofishCipher.csproj b/src/TwofishCipher/TwofishCipher.csproj index 6ae180c2..499cb874 100644 --- a/src/TwofishCipher/TwofishCipher.csproj +++ b/src/TwofishCipher/TwofishCipher.csproj @@ -1,6 +1,6 @@ - net8.0-android + net9.0-android 21 enable enable diff --git a/src/ZlibAndroid/ZlibAndroid.csproj b/src/ZlibAndroid/ZlibAndroid.csproj index 5b3ea69e..17ad3f2b 100644 --- a/src/ZlibAndroid/ZlibAndroid.csproj +++ b/src/ZlibAndroid/ZlibAndroid.csproj @@ -1,6 +1,6 @@ - net8.0-android + net9.0-android 21 enable enable diff --git a/src/keepass2android-app/GeneratePasswordActivity.cs b/src/keepass2android-app/GeneratePasswordActivity.cs index e187a01e..46f3da0d 100644 --- a/src/keepass2android-app/GeneratePasswordActivity.cs +++ b/src/keepass2android-app/GeneratePasswordActivity.cs @@ -145,12 +145,14 @@ namespace keepass2android protected override void OnCreate(Bundle savedInstanceState) { _design.ApplyTheme(); base.OnCreate(savedInstanceState); - + SetContentView(Resource.Layout.generate_password); SetResult(KeePass.ExitNormal); - - var prefs = GetPreferences(FileCreationMode.Private); + new Util.InsetListener(FindViewById(Resource.Id.main_container)).Apply(); + + + var prefs = GetPreferences(FileCreationMode.Private); diff --git a/src/keepass2android-app/Manifests/AndroidManifest_debug.xml b/src/keepass2android-app/Manifests/AndroidManifest_debug.xml index e9b17aaa..dde3f6a9 100644 --- a/src/keepass2android-app/Manifests/AndroidManifest_debug.xml +++ b/src/keepass2android-app/Manifests/AndroidManifest_debug.xml @@ -43,7 +43,7 @@ - + - + diff --git a/src/keepass2android-app/Manifests/AndroidManifest_nonet.xml b/src/keepass2android-app/Manifests/AndroidManifest_nonet.xml index 1b734e8c..bb1ea140 100644 --- a/src/keepass2android-app/Manifests/AndroidManifest_nonet.xml +++ b/src/keepass2android-app/Manifests/AndroidManifest_nonet.xml @@ -42,7 +42,7 @@ - + diff --git a/src/keepass2android-app/PasswordActivity.cs b/src/keepass2android-app/PasswordActivity.cs index 9cd6d54b..96c6bd1f 100644 --- a/src/keepass2android-app/PasswordActivity.cs +++ b/src/keepass2android-app/PasswordActivity.cs @@ -15,6 +15,36 @@ This file is part of Keepass2Android, Copyright 2013 Philipp Crocoll. This file along with Keepass2Android. If not, see . */ +using Android.App; +using Android.Content; +using Android.Content.PM; +using Android.Database; +using Android.Graphics; +using Android.Graphics.Drawables; +using Android.OS; +using Android.Preferences; +using Android.Runtime; +using Android.Text; +using Android.Views; +using Android.Views.InputMethods; +using Android.Widget; +using AndroidX.AppCompat.App; +using AndroidX.CoordinatorLayout.Widget; +using AndroidX.Core.Content; +using AndroidX.Core.View; +using AndroidX.DrawerLayout.Widget; +using Google.Android.Material.AppBar; +using Google.Android.Material.Dialog; +using Java.Lang; +using Java.Net; +using KeeChallenge; +using keepass2android; +using keepass2android.Io; +using keepass2android.Utils; +using Keepass2android.Pluginsdk; +using KeePassLib.Keys; +using KeePassLib.Serialization; +using OtpKeyProv; using System; using System.Collections.Generic; using System.IO; @@ -23,49 +53,17 @@ using System.Net; using System.Threading.Tasks; using System.Xml; using System.Xml.Serialization; -using keepass2android; -using Android.App; -using Android.Content; -using Android.Database; -using Android.Graphics.Drawables; -using Android.OS; -using Android.Runtime; -using Android.Views; -using Android.Views.InputMethods; -using Android.Widget; -using Java.Net; -using Android.Preferences; -using Android.Text; -using Android.Content.PM; -using Android.Graphics; -using AndroidX.AppCompat.App; -using AndroidX.CoordinatorLayout.Widget; -using AndroidX.Core.View; -using AndroidX.DrawerLayout.Widget; -using Google.Android.Material.AppBar; -using Google.Android.Material.Dialog; -using Java.Lang; -using KeePassLib.Keys; -using KeePassLib.Serialization; -using Keepass2android.Pluginsdk; -using OtpKeyProv; -using keepass2android.Io; -using keepass2android.Utils; - -using File = Java.IO.File; -using FileNotFoundException = Java.IO.FileNotFoundException; - -using Object = Java.Lang.Object; -using Process = Android.OS.Process; - -using KeeChallenge; +using static Android.Locations.GpsStatus; using AlertDialog = Android.App.AlertDialog; using ClipboardManager = Android.Content.ClipboardManager; using Enum = System.Enum; using Exception = System.Exception; +using File = Java.IO.File; +using FileNotFoundException = Java.IO.FileNotFoundException; +using Object = Java.Lang.Object; +using Process = Android.OS.Process; using String = System.String; using Toolbar = AndroidX.AppCompat.Widget.Toolbar; -using AndroidX.Core.Content; namespace keepass2android { @@ -651,7 +649,7 @@ namespace keepass2android _activityDesign.ApplyTheme(); base.OnCreate(savedInstanceState); - _intentReceiver = new PasswordActivityBroadcastReceiver(this); + _intentReceiver = new PasswordActivityBroadcastReceiver(this); IntentFilter filter = new IntentFilter(); filter.AddAction(Intent.ActionScreenOff); ContextCompat.RegisterReceiver(this, _intentReceiver, filter, (int)ReceiverFlags.Exported); @@ -1165,7 +1163,9 @@ namespace keepass2android changeDbButton.Click += (sender, args) => GoToFileSelectActivity(); Util.MoveBottomBarButtons(Resource.Id.change_db, Resource.Id.pass_ok, Resource.Id.bottom_bar, this); - } + Util.InsetListener.ForBottomElement(FindViewById(Resource.Id.bottom_bar)).Apply(); + Util.InsetListener.ForTopElement(FindViewById(Resource.Id.appbar)).Apply(); + } private void OnOk(bool usedFingerprintUnlock = false) { diff --git a/src/keepass2android-app/QuickUnlock.cs b/src/keepass2android-app/QuickUnlock.cs index 4a8b35fa..d57fd51f 100644 --- a/src/keepass2android-app/QuickUnlock.cs +++ b/src/keepass2android-app/QuickUnlock.cs @@ -81,8 +81,11 @@ namespace keepass2android SetContentView(Resource.Layout.QuickUnlock); + Util.InsetListener.ForBottomElement(FindViewById(Resource.Id.bottom_bar)).Apply(); + Util.InsetListener.ForTopElement(FindViewById(Resource.Id.appbar)).Apply(); - var collapsingToolbar = FindViewById(Resource.Id.collapsing_toolbar); + + var collapsingToolbar = FindViewById(Resource.Id.collapsing_toolbar); collapsingToolbar.SetTitle(GetString(Resource.String.QuickUnlock_prefs)); SetSupportActionBar(FindViewById(Resource.Id.toolbar)); diff --git a/src/keepass2android-app/Resources/layout/QuickUnlock.xml b/src/keepass2android-app/Resources/layout/QuickUnlock.xml index 0c4da5c4..70bd4b02 100644 --- a/src/keepass2android-app/Resources/layout/QuickUnlock.xml +++ b/src/keepass2android-app/Resources/layout/QuickUnlock.xml @@ -1,11 +1,11 @@ +android:fitsSystemWindows="false"> android:layout_width="match_parent" android:layout_height="match_parent" android:layout_weight="1" - android:fitsSystemWindows="true"> + android:fitsSystemWindows="false"> android:layout_width="match_parent" android:layout_height="match_parent" app:layout_scrollFlags="scroll|exitUntilCollapsed" - android:fitsSystemWindows="true" + android:fitsSystemWindows="false" app:expandedTitleMarginStart="16dp" app:expandedTitleMarginEnd="24dp" app:expandedTitleMarginBottom="20sp"> diff --git a/src/keepass2android-app/Resources/layout/generate_password.xml b/src/keepass2android-app/Resources/layout/generate_password.xml index 6eca0d7f..351c7bd7 100644 --- a/src/keepass2android-app/Resources/layout/generate_password.xml +++ b/src/keepass2android-app/Resources/layout/generate_password.xml @@ -1,5 +1,6 @@ @@ -322,4 +323,3 @@ - diff --git a/src/keepass2android-app/Resources/layout/password.xml b/src/keepass2android-app/Resources/layout/password.xml index b21a343f..af9a3745 100644 --- a/src/keepass2android-app/Resources/layout/password.xml +++ b/src/keepass2android-app/Resources/layout/password.xml @@ -1,10 +1,10 @@ - +> + android:layout_weight="1"> @@ -446,4 +448,4 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/src/keepass2android-app/Resources/values-night-v35/themes.xml b/src/keepass2android-app/Resources/values-night-v35/themes.xml new file mode 100644 index 00000000..86a3ae7f --- /dev/null +++ b/src/keepass2android-app/Resources/values-night-v35/themes.xml @@ -0,0 +1,22 @@ + + + + + + + + + \ No newline at end of file diff --git a/src/keepass2android-app/Resources/values-v35/themes.xml b/src/keepass2android-app/Resources/values-v35/themes.xml new file mode 100644 index 00000000..3bf426f4 --- /dev/null +++ b/src/keepass2android-app/Resources/values-v35/themes.xml @@ -0,0 +1,22 @@ + + + + + + + + + \ No newline at end of file diff --git a/src/keepass2android-app/Resources/values/dimens.xml b/src/keepass2android-app/Resources/values/dimens.xml index dbc57788..982af1db 100644 --- a/src/keepass2android-app/Resources/values/dimens.xml +++ b/src/keepass2android-app/Resources/values/dimens.xml @@ -4,7 +4,7 @@ 16dp 16dp - 200dp + 250dp 16dp 79dp diff --git a/src/keepass2android-app/Resources/values/themes.xml b/src/keepass2android-app/Resources/values/themes.xml index 9635d989..d9b6d6fd 100644 --- a/src/keepass2android-app/Resources/values/themes.xml +++ b/src/keepass2android-app/Resources/values/themes.xml @@ -253,12 +253,12 @@ @color/statusbar_color_green - + +