Create an AccountChooserActivity to choose an account.

Benefits of the refactor:
- can support screen rotation when choosing an account
- reduce complexity in SendActivity

Also change the minSdkVersion to 7 so that
- in AccountChooserActivity, can just use the Android AccountManager
- in SendActivity, can use Account
- in SendActivity, can remove the Constants.GET_LOGIN callback
  from the legacy AuthManager (AuthManagerOld)
This commit is contained in:
Jimmy Shih
2012-01-12 12:54:42 -08:00
parent 8f72c36351
commit 4a0a2a8856
7 changed files with 254 additions and 127 deletions
@@ -35,8 +35,11 @@ public abstract class Constants {
/*
* onActivityResult request codes:
*
* TODO: These should be moved to the
* activities that call startActivityForResult. Thus do not need to keep a
* global order across all activities.
*/
public static final int GET_LOGIN = 0;
public static final int GET_MAP = 1;
public static final int SHOW_TRACK = 2;
@@ -54,6 +57,7 @@ public abstract class Constants {
public static final int SAVE_TCX_FILE = 14;
public static final int SHOW_WAYPOINT = 15;
public static final int WELCOME = 16;
public static final int CHOOSE_ACCOUNT = 17;
/*
* Menu ids: