diff options
author | Zeapo <mohamed@zenadi.com> | 2014-08-10 13:52:58 +0100 |
---|---|---|
committer | Zeapo <mohamed@zenadi.com> | 2014-08-10 13:52:58 +0100 |
commit | 1e3a2a8ae7a1aa8a2e9e213afb5dbc57bbdb8d8d (patch) | |
tree | a6b6c63a714c9633ac476c6c1aa690076f11dd95 /app | |
parent | 265ac86903f6a35fccbc96ec781bad26b0c5c268 (diff) |
access settings from githandler activity
Diffstat (limited to 'app')
-rw-r--r-- | app/src/main/java/com/zeapo/pwdstore/GitHandler.java | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/app/src/main/java/com/zeapo/pwdstore/GitHandler.java b/app/src/main/java/com/zeapo/pwdstore/GitHandler.java index 977a45ba..c6f1bb79 100644 --- a/app/src/main/java/com/zeapo/pwdstore/GitHandler.java +++ b/app/src/main/java/com/zeapo/pwdstore/GitHandler.java @@ -5,6 +5,7 @@ import android.app.AlertDialog; import android.app.ProgressDialog; import android.content.Context; import android.content.DialogInterface; +import android.content.Intent; import android.content.SharedPreferences; import android.os.AsyncTask; import android.os.Bundle; @@ -189,8 +190,16 @@ public class GitHandler extends Activity { // automatically handle clicks on the Home/Up button, so long // as you specify a parent activity in AndroidManifest.xml. int id = item.getItemId(); - if (id == R.id.action_settings) { - return true; + switch (id) { + case R.id.user_pref: + try { + Intent intent = new Intent(this, UserPreference.class); + startActivity(intent); + } catch (Exception e) { + System.out.println("Exception caught :("); + e.printStackTrace(); + } + return true; } return super.onOptionsItemSelected(item); } |