From 530453025c1b0b90eb559e5480d57584b94ba661 Mon Sep 17 00:00:00 2001 From: zeapo Date: Thu, 18 Dec 2014 21:51:09 +0100 Subject: correct a typo for saved protocol/authmode --- .../main/java/com/zeapo/pwdstore/git/GitActivity.java | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'app/src') diff --git a/app/src/main/java/com/zeapo/pwdstore/git/GitActivity.java b/app/src/main/java/com/zeapo/pwdstore/git/GitActivity.java index 551f17e3..5bb44b32 100644 --- a/app/src/main/java/com/zeapo/pwdstore/git/GitActivity.java +++ b/app/src/main/java/com/zeapo/pwdstore/git/GitActivity.java @@ -102,13 +102,6 @@ public class GitActivity extends ActionBarActivity { } }); - - if (protocol.equals("ssh://")) { - protcol_spinner.setSelection(0); - } else { - protcol_spinner.setSelection(1); - } - // init the spinner for protocols ArrayAdapter protocol_adapter = ArrayAdapter.createFromResource(this, R.array.clone_protocols, android.R.layout.simple_spinner_item); @@ -145,12 +138,18 @@ public class GitActivity extends ActionBarActivity { } ); - if (connectionMode.equals("ssh-key")) { + if (protocol.equals("ssh://")) { protcol_spinner.setSelection(0); } else { protcol_spinner.setSelection(1); } + if (connectionMode.equals("ssh-key")) { + connection_mode_spinner.setSelection(0); + } else { + connection_mode_spinner.setSelection(1); + } + // init the server information final EditText server_url = ((EditText) findViewById(R.id.server_url)); final EditText server_port = ((EditText) findViewById(R.id.server_port)); @@ -255,6 +254,7 @@ public class GitActivity extends ActionBarActivity { findViewById(R.id.save_button).setVisibility(View.INVISIBLE); } + updateURI(); break; case REQUEST_PULL: -- cgit v1.2.3