add option to toggle self-encrypt for text

This commit is contained in:
Vincent Breitmoser
2018-03-05 14:02:48 +01:00
parent 285184d7c6
commit 3fdc4059b5
4 changed files with 54 additions and 2 deletions

View File

@@ -217,6 +217,16 @@ public class Preferences {
return mSharedPreferences.getBoolean(Pref.TEXT_USE_COMPRESSION, true);
}
public void setTextSelfEncrypt(boolean selfEncrypt) {
SharedPreferences.Editor editor = mSharedPreferences.edit();
editor.putBoolean(Pref.TEXT_SELF_ENCRYPT, selfEncrypt);
editor.commit();
}
public boolean getTextSelfEncrypt() {
return mSharedPreferences.getBoolean(Pref.TEXT_SELF_ENCRYPT, true);
}
public String getTheme() {
return mSharedPreferences.getString(Pref.THEME, Pref.Theme.LIGHT);
}