|
|
@ -252,6 +252,9 @@ public class ServiceSynchronize extends ServiceBase implements SharedPreferences
|
|
|
|
if (account > 0 && !current.accountState.id.equals(account))
|
|
|
|
if (account > 0 && !current.accountState.id.equals(account))
|
|
|
|
continue;
|
|
|
|
continue;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
boolean sync = current.command.getBoolean("sync", false);
|
|
|
|
|
|
|
|
boolean force = current.command.getBoolean("force", false);
|
|
|
|
|
|
|
|
|
|
|
|
int index = accountStates.indexOf(current);
|
|
|
|
int index = accountStates.indexOf(current);
|
|
|
|
if (index < 0) {
|
|
|
|
if (index < 0) {
|
|
|
|
if (current.canRun()) {
|
|
|
|
if (current.canRun()) {
|
|
|
@ -266,12 +269,10 @@ public class ServiceSynchronize extends ServiceBase implements SharedPreferences
|
|
|
|
" state=" + current.accountState.state +
|
|
|
|
" state=" + current.accountState.state +
|
|
|
|
" active=" + current.networkState.getActive());
|
|
|
|
" active=" + current.networkState.getActive());
|
|
|
|
event = true;
|
|
|
|
event = true;
|
|
|
|
start(current, current.accountState.isEnabled(current.enabled), false);
|
|
|
|
start(current, current.accountState.isEnabled(current.enabled) || sync, force);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
boolean reload = false;
|
|
|
|
boolean reload = false;
|
|
|
|
boolean sync = current.command.getBoolean("sync", false);
|
|
|
|
|
|
|
|
boolean force = current.command.getBoolean("force", false);
|
|
|
|
|
|
|
|
switch (current.command.getString("name")) {
|
|
|
|
switch (current.command.getString("name")) {
|
|
|
|
case "reload":
|
|
|
|
case "reload":
|
|
|
|
reload = true;
|
|
|
|
reload = true;
|
|
|
|