1
0
Fork 0
mirror of https://github.com/M66B/FairEmail.git synced 2025-03-06 03:33:07 +00:00

Global enabled / schedule

This commit is contained in:
M66B 2019-07-05 20:36:41 +02:00
parent f906271b0c
commit 4a25cbe269

View file

@ -94,6 +94,8 @@ public class FragmentOptionsSynchronize extends FragmentBase implements SharedPr
public void onCheckedChanged(CompoundButton compoundButton, boolean checked) {
prefs.edit().putBoolean("enabled", checked).apply();
spPollInterval.setEnabled(checked);
if (!checked)
swSchedule.setChecked(false);
ServiceSynchronize.reload(getContext(), true, "enabled=" + checked);
}
});
@ -125,6 +127,8 @@ public class FragmentOptionsSynchronize extends FragmentBase implements SharedPr
@Override
public void onCheckedChanged(CompoundButton compoundButton, boolean checked) {
prefs.edit().putBoolean("schedule", checked).apply();
if (checked)
swEnabled.setChecked(true);
}
});