Check that the string resources work
This commit is contained in:
parent
9f9f99dc24
commit
af2c0ab0e1
2 changed files with 13 additions and 5 deletions
|
@ -53,7 +53,7 @@ public class PasswordStore extends ActionBarActivity {
|
|||
super.onResume();
|
||||
|
||||
// create the repository static variable in PasswordRepository
|
||||
PasswordRepository.getRepository(new File(getFilesDir() + "/store/.git"));
|
||||
PasswordRepository.getRepository(new File(getFilesDir() + this.getResources().getString(R.string.git_store)));
|
||||
|
||||
// re-check that there was no change with the repository state
|
||||
checkLocalRepository();
|
||||
|
@ -111,8 +111,8 @@ public class PasswordStore extends ActionBarActivity {
|
|||
Log.d("PASS", "Menu item " + id + " pressed");
|
||||
|
||||
AlertDialog.Builder initBefore = new AlertDialog.Builder(this)
|
||||
.setMessage("Please clone or create a new repository below before trying to add a password or any synchronization operation.")
|
||||
.setPositiveButton("OK", new DialogInterface.OnClickListener() {
|
||||
.setMessage(this.getResources().getString(R.string.creation_alert_text));
|
||||
.setPositiveButton(this.getResources().getString(R.string.ok), new DialogInterface.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(DialogInterface dialogInterface, int i) {
|
||||
}
|
||||
|
@ -205,7 +205,7 @@ public class PasswordStore extends ActionBarActivity {
|
|||
GitAsyncTask tasks = new GitAsyncTask(this, false, false, CommitCommand.class);
|
||||
tasks.execute(
|
||||
git.add().addFilepattern("."),
|
||||
git.commit().setMessage("[ANDROID PwdStore] Initialized store with keyID: " + keyId)
|
||||
git.commit().setMessage(R.string.initialization_commit_text + keyId)
|
||||
);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
|
|
|
@ -13,7 +13,12 @@
|
|||
<string name="dialog_delete">Delete directory</string>
|
||||
<string name="dialog_do_not_delete">Cancel</string>
|
||||
<string name="title_activity_git_clone">Clone repository</string>
|
||||
|
||||
|
||||
<!-- Password Store -->
|
||||
<string name="creation_dialog_text">Please clone or create a new repository below before trying to add a password or any synchronization operation.</strng>
|
||||
<string name="initialization_commit_text">[ANDROID PwdStore] Initialized store with keyID: </string>
|
||||
<string name="store_git">/store/.git</string>
|
||||
|
||||
<!-- Clone fragment -->
|
||||
<string name="clone_fragment_text">Welcome to Password Store\n\n In this screen you can either create a new repository or clone your git repository onto your device.</string>
|
||||
<string name="clone">Clone existing</string>
|
||||
|
@ -43,6 +48,9 @@
|
|||
<!-- DECRYPT Layout -->
|
||||
<string name="crypto_category">Category</string>
|
||||
<string name="action_search">Search</string>
|
||||
|
||||
<!-- Misc -->
|
||||
<string name="ok">OK</string>
|
||||
|
||||
|
||||
</resources>
|
||||
|
|
Loading…
Reference in a new issue