summaryrefslogtreecommitdiff
path: root/app/src/main/java
diff options
context:
space:
mode:
authorHarsh Shandilya <me@msfjarvis.dev>2022-10-29 04:16:08 +0530
committerHarsh Shandilya <me@msfjarvis.dev>2022-10-29 04:16:08 +0530
commit390286f95fffdfad434f60a460fff21473fefc32 (patch)
tree8fa5e7760eab16c125eee6e4dd6ecf3d4cc82074 /app/src/main/java
parent2c78f8303a5ab0a72fd018b1a504529bbb06955e (diff)
feat: add a no-op ASCII armor toggle
Diffstat (limited to 'app/src/main/java')
-rw-r--r--app/src/main/java/app/passwordstore/ui/settings/PGPSettings.kt6
-rw-r--r--app/src/main/java/app/passwordstore/util/settings/PreferenceKeys.kt1
2 files changed, 7 insertions, 0 deletions
diff --git a/app/src/main/java/app/passwordstore/ui/settings/PGPSettings.kt b/app/src/main/java/app/passwordstore/ui/settings/PGPSettings.kt
index d44fd365..302d9300 100644
--- a/app/src/main/java/app/passwordstore/ui/settings/PGPSettings.kt
+++ b/app/src/main/java/app/passwordstore/ui/settings/PGPSettings.kt
@@ -9,9 +9,11 @@ import androidx.fragment.app.FragmentActivity
import app.passwordstore.ui.pgp.PGPKeyImportActivity
import app.passwordstore.ui.pgp.PGPKeyListActivity
import app.passwordstore.util.extensions.launchActivity
+import app.passwordstore.util.settings.PreferenceKeys
import de.Maxr1998.modernpreferences.PreferenceScreen
import de.Maxr1998.modernpreferences.helpers.onClick
import de.Maxr1998.modernpreferences.helpers.pref
+import de.Maxr1998.modernpreferences.helpers.switch
class PGPSettings(private val activity: FragmentActivity) : SettingsProvider {
@@ -33,6 +35,10 @@ class PGPSettings(private val activity: FragmentActivity) : SettingsProvider {
false
}
}
+ switch(PreferenceKeys.ASCII_ARMOR) {
+ title = "Encrypt in ASCII armor mode"
+ persistent = true
+ }
}
}
}
diff --git a/app/src/main/java/app/passwordstore/util/settings/PreferenceKeys.kt b/app/src/main/java/app/passwordstore/util/settings/PreferenceKeys.kt
index 16edb4c7..cb143d1a 100644
--- a/app/src/main/java/app/passwordstore/util/settings/PreferenceKeys.kt
+++ b/app/src/main/java/app/passwordstore/util/settings/PreferenceKeys.kt
@@ -85,4 +85,5 @@ object PreferenceKeys {
const val DICEWARE_SEPARATOR = "diceware_separator"
const val DICEWARE_LENGTH = "diceware_length"
const val DISABLE_SYNC_ACTION = "disable_sync_action"
+ const val ASCII_ARMOR = "pgpainless_ascii_armor"
}