mirror of
https://github.com/M66B/FairEmail.git
synced 2026-04-01 22:56:33 +02:00
Set first new account/identity primary only
This commit is contained in:
@@ -436,6 +436,19 @@ public class FragmentIdentity extends FragmentEx {
|
||||
cbStoreSent.setChecked(identity == null ? false : identity.store_sent);
|
||||
|
||||
etName.requestFocus();
|
||||
|
||||
if (identity == null)
|
||||
new SimpleTask<Integer>() {
|
||||
@Override
|
||||
protected Integer onLoad(Context context, Bundle args) {
|
||||
return DB.getInstance(context).identity().getSynchronizingIdentityCount();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onLoaded(Bundle args, Integer count) {
|
||||
cbPrimary.setChecked(count == 0);
|
||||
}
|
||||
}.load(FragmentIdentity.this, new Bundle());
|
||||
} else {
|
||||
tilPassword.getEditText().setText(savedInstanceState.getString("password"));
|
||||
grpAdvanced.setVisibility(savedInstanceState.getInt("advanced"));
|
||||
|
||||
Reference in New Issue
Block a user