diff options
author | Dominik Schürmann <dominik@dominikschuermann.de> | 2014-07-03 16:49:25 +0200 |
---|---|---|
committer | Dominik Schürmann <dominik@dominikschuermann.de> | 2014-07-03 16:49:25 +0200 |
commit | 709196f774fc24dc0e7e6440391113f6be1e8e3a (patch) | |
tree | a064c55db7b29b581aa1365b9a32855c2efa52b1 /OpenKeychain/src/main | |
parent | e006d4762ce2b995425fa8e15e5fb99f6c377558 (diff) | |
download | open-keychain-709196f774fc24dc0e7e6440391113f6be1e8e3a.tar.gz open-keychain-709196f774fc24dc0e7e6440391113f6be1e8e3a.tar.bz2 open-keychain-709196f774fc24dc0e7e6440391113f6be1e8e3a.zip |
Use strings in edit key
Diffstat (limited to 'OpenKeychain/src/main')
3 files changed, 18 insertions, 7 deletions
diff --git a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/dialog/EditUserIdDialogFragment.java b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/dialog/EditUserIdDialogFragment.java index f0ca73f0d..5eba3a463 100644 --- a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/dialog/EditUserIdDialogFragment.java +++ b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/dialog/EditUserIdDialogFragment.java @@ -26,6 +26,7 @@ import android.os.RemoteException; import android.support.v4.app.DialogFragment; import org.sufficientlysecure.keychain.Constants; +import org.sufficientlysecure.keychain.R; import org.sufficientlysecure.keychain.util.Log; public class EditUserIdDialogFragment extends DialogFragment { @@ -57,9 +58,9 @@ public class EditUserIdDialogFragment extends DialogFragment { mMessenger = getArguments().getParcelable(ARG_MESSENGER); CustomAlertDialogBuilder builder = new CustomAlertDialogBuilder(getActivity()); - CharSequence[] array = {"change to primary user id", "revoke"}; + CharSequence[] array = getResources().getStringArray(R.array.edit_key_edit_user_id); - builder.setTitle("select action!"); + builder.setTitle(R.string.edit_key_edit_user_id_title); builder.setItems(array, new DialogInterface.OnClickListener() { @Override @@ -76,7 +77,7 @@ public class EditUserIdDialogFragment extends DialogFragment { } } }); - builder.setNegativeButton("cancel", new DialogInterface.OnClickListener() { + builder.setNegativeButton(android.R.string.cancel, new DialogInterface.OnClickListener() { @Override public void onClick(DialogInterface dialog, int id) { dismiss(); diff --git a/OpenKeychain/src/main/res/layout/edit_key_fragment.xml b/OpenKeychain/src/main/res/layout/edit_key_fragment.xml index 0570784d0..2ffbc66f4 100644 --- a/OpenKeychain/src/main/res/layout/edit_key_fragment.xml +++ b/OpenKeychain/src/main/res/layout/edit_key_fragment.xml @@ -14,7 +14,7 @@ android:layout_width="wrap_content" android:layout_height="0dp" android:layout_marginTop="8dp" - android:text="Passphrase" + android:text="@string/label_passphrase" android:layout_weight="1" /> <TextView @@ -24,7 +24,7 @@ android:textAppearance="?android:attr/textAppearanceMedium" android:layout_width="match_parent" android:layout_height="match_parent" - android:text="change passphrase" + android:text="@string/edit_key_action_change_passphrase" android:minHeight="?android:attr/listPreferredItemHeight" android:drawableRight="@drawable/ic_action_edit" android:drawablePadding="8dp" @@ -67,7 +67,7 @@ android:textAppearance="?android:attr/textAppearanceMedium" android:layout_width="match_parent" android:layout_height="match_parent" - android:text="add identity" + android:text="@string/edit_key_action_add_identity" android:minHeight="?android:attr/listPreferredItemHeight" android:drawableRight="@drawable/ic_action_add_person" android:drawablePadding="8dp" @@ -109,7 +109,7 @@ android:textAppearance="?android:attr/textAppearanceMedium" android:layout_width="match_parent" android:layout_height="match_parent" - android:text="add key" + android:text="@string/edit_key_action_add_subkey" android:minHeight="?android:attr/listPreferredItemHeight" android:drawableRight="@drawable/ic_action_new_account" android:drawablePadding="8dp" diff --git a/OpenKeychain/src/main/res/values/strings.xml b/OpenKeychain/src/main/res/values/strings.xml index e437b8d52..cffd234d2 100644 --- a/OpenKeychain/src/main/res/values/strings.xml +++ b/OpenKeychain/src/main/res/values/strings.xml @@ -471,6 +471,16 @@ <string name="key_view_tab_keys">Subkeys</string> <string name="key_view_tab_certs">Certificates</string> + <!-- Edit key --> + <string name="edit_key_action_change_passphrase">Change Passphrase</string> + <string name="edit_key_action_add_identity">Add Identity</string> + <string name="edit_key_action_add_subkey">Add Subkey</string> + <string name="edit_key_edit_user_id_title">Select an action!</string> + <string-array name="edit_key_edit_user_id"> + <item>Change to Primary Identity</item> + <item>Revoke Identity</item> + </string-array> + <!-- Navigation Drawer --> <string name="nav_keys">Keys</string> <string name="nav_encrypt">Sign and Encrypt</string> |