|
|
|
@ -1166,10 +1166,13 @@ public class ServiceSynchronize extends ServiceBase implements SharedPreferences
|
|
|
|
|
try {
|
|
|
|
|
db.beginTransaction();
|
|
|
|
|
|
|
|
|
|
for (Message imessage : e.getMessages()) {
|
|
|
|
|
long uid = ifolder.getUID(imessage);
|
|
|
|
|
EntityOperation.queue(ServiceSynchronize.this, folder, EntityOperation.FETCH, uid);
|
|
|
|
|
}
|
|
|
|
|
if (e.getMessages().length > Core.MAX_FETCH)
|
|
|
|
|
EntityOperation.sync(ServiceSynchronize.this, folder.id, false);
|
|
|
|
|
else
|
|
|
|
|
for (Message imessage : e.getMessages()) {
|
|
|
|
|
long uid = ifolder.getUID(imessage);
|
|
|
|
|
EntityOperation.queue(ServiceSynchronize.this, folder, EntityOperation.FETCH, uid);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
db.setTransactionSuccessful();
|
|
|
|
|
} finally {
|
|
|
|
@ -1195,10 +1198,13 @@ public class ServiceSynchronize extends ServiceBase implements SharedPreferences
|
|
|
|
|
try {
|
|
|
|
|
db.beginTransaction();
|
|
|
|
|
|
|
|
|
|
for (Message imessage : e.getMessages()) {
|
|
|
|
|
long uid = ifolder.getUID(imessage);
|
|
|
|
|
EntityOperation.queue(ServiceSynchronize.this, folder, EntityOperation.FETCH, uid, true);
|
|
|
|
|
}
|
|
|
|
|
if (e.getMessages().length > Core.MAX_FETCH)
|
|
|
|
|
EntityOperation.sync(ServiceSynchronize.this, folder.id, false);
|
|
|
|
|
else
|
|
|
|
|
for (Message imessage : e.getMessages()) {
|
|
|
|
|
long uid = ifolder.getUID(imessage);
|
|
|
|
|
EntityOperation.queue(ServiceSynchronize.this, folder, EntityOperation.FETCH, uid, true);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
db.setTransactionSuccessful();
|
|
|
|
|
} finally {
|
|
|
|
|