1
0
mirror of https://github.com/moparisthebest/k-9 synced 2025-02-17 07:30:16 -05:00

Remove duplicated "make this account the default" option during setup

This commit is contained in:
Jesse Vincent 2009-11-16 19:33:23 +00:00
parent 84ab290046
commit 4cc22f8208
2 changed files with 2 additions and 13 deletions

View File

@ -44,12 +44,6 @@
android:id="@+id/account_display_count"
android:layout_height="wrap_content"
android:layout_width="fill_parent" />
<CheckBox
android:id="@+id/account_default"
android:layout_height="wrap_content"
android:layout_width="fill_parent"
android:textColor="?android:attr/textColorPrimary"
android:text="@string/account_setup_options_default_label" />
<CheckBox
android:id="@+id/account_notify"
android:layout_height="wrap_content"

View File

@ -27,7 +27,6 @@ public class AccountSetupOptions extends K9Activity implements OnClickListener {
private Spinner mDisplayCountView;
private CheckBox mDefaultView;
private CheckBox mNotifyView;
private CheckBox mNotifySyncView;
@ -49,7 +48,6 @@ public class AccountSetupOptions extends K9Activity implements OnClickListener {
mCheckFrequencyView = (Spinner)findViewById(R.id.account_check_frequency);
mDisplayCountView = (Spinner)findViewById(R.id.account_display_count);
mDefaultView = (CheckBox)findViewById(R.id.account_default);
mNotifyView = (CheckBox)findViewById(R.id.account_notify);
mNotifySyncView = (CheckBox)findViewById(R.id.account_notify_sync);
mPushEnable = (CheckBox)findViewById(R.id.account_enable_push);
@ -107,11 +105,7 @@ public class AccountSetupOptions extends K9Activity implements OnClickListener {
mDisplayCountView.setAdapter(displayCountsAdapter);
mAccount = (Account)getIntent().getSerializableExtra(EXTRA_ACCOUNT);
boolean makeDefault = getIntent().getBooleanExtra(EXTRA_MAKE_DEFAULT, false);
if (mAccount.equals(Preferences.getPreferences(this).getDefaultAccount()) || makeDefault) {
mDefaultView.setChecked(true);
}
mNotifyView.setChecked(mAccount.isNotifyNewMail());
mNotifySyncView.setChecked(mAccount.isShowOngoing());
SpinnerOption.setSpinnerOptionValue(mCheckFrequencyView, mAccount
@ -157,7 +151,8 @@ public class AccountSetupOptions extends K9Activity implements OnClickListener {
}
mAccount.save(Preferences.getPreferences(this));
if (mDefaultView.isChecked()) {
if (mAccount.equals(Preferences.getPreferences(this).getDefaultAccount()) ||
getIntent().getBooleanExtra(EXTRA_MAKE_DEFAULT, false) ) {
Preferences.getPreferences(this).setDefaultAccount(mAccount);
}
Email.setServicesEnabled(this);