mirror of
https://github.com/M66B/FairEmail.git
synced 2025-12-30 09:31:11 +01:00
Added account/identity copy
This commit is contained in:
@@ -124,6 +124,7 @@ public class FragmentIdentity extends FragmentBase {
|
||||
private Group grpAdvanced;
|
||||
|
||||
private long id = -1;
|
||||
private long copy = -1;
|
||||
private boolean saving = false;
|
||||
private int color = Color.TRANSPARENT;
|
||||
|
||||
@@ -138,7 +139,10 @@ public class FragmentIdentity extends FragmentBase {
|
||||
|
||||
// Get arguments
|
||||
Bundle args = getArguments();
|
||||
id = args.getLong("id", -1);
|
||||
if (args.getBoolean("copy"))
|
||||
copy = args.getLong("id", -1);
|
||||
else
|
||||
id = args.getLong("id", -1);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -826,7 +830,7 @@ public class FragmentIdentity extends FragmentBase {
|
||||
super.onActivityCreated(savedInstanceState);
|
||||
|
||||
Bundle args = new Bundle();
|
||||
args.putLong("id", id);
|
||||
args.putLong("id", copy < 0 ? id : copy);
|
||||
|
||||
new SimpleTask<EntityIdentity>() {
|
||||
@Override
|
||||
@@ -867,7 +871,7 @@ public class FragmentIdentity extends FragmentBase {
|
||||
|
||||
color = (identity == null || identity.color == null ? Color.TRANSPARENT : identity.color);
|
||||
|
||||
if (identity == null)
|
||||
if (identity == null || copy > 0)
|
||||
new SimpleTask<Integer>() {
|
||||
@Override
|
||||
protected Integer onExecute(Context context, Bundle args) {
|
||||
|
||||
Reference in New Issue
Block a user