[geary] Allow flag watching while synchronizing folder in background



commit a91854616a83ba60aa9074eac7f256361178676c
Author: Jim Nelson <jim yorba org>
Date:   Mon Feb 3 13:56:43 2014 -0800

    Allow flag watching while synchronizing folder in background
    
    Previously, synchronizing folders caused a jump in CPU, so work was
    done to minimize activity.  Optimizations to folder normalization
    has reduced the CPU load, so it's okay now to allow flag watching
    while the background folder is open.
    
    This is not a substitute for an architected solution: periodic
    flag synchronization with folders, not merely when changes in contents
    (additions/removals) are detected, but this helps some, especially
    with high-traffic folders.

 .../imap-engine-account-synchronizer.vala          |    6 ------
 1 files changed, 0 insertions(+), 6 deletions(-)
---
diff --git a/src/engine/imap-engine/imap-engine-account-synchronizer.vala 
b/src/engine/imap-engine/imap-engine-account-synchronizer.vala
index 76f4987..fcc4c93 100644
--- a/src/engine/imap-engine/imap-engine-account-synchronizer.vala
+++ b/src/engine/imap-engine/imap-engine-account-synchronizer.vala
@@ -306,10 +306,6 @@ private class Geary.ImapEngine.AccountSynchronizer : Geary.BaseObject {
             return true;
         }
         
-        // turn off the flag watcher whilst synchronizing, as that can cause addt'l load on the
-        // CPU
-        folder.email_flag_watcher.enabled = false;
-        
         try {
             yield sync_folder_async(folder, epoch, oldest_local, oldest_local_id);
         } catch (Error err) {
@@ -319,8 +315,6 @@ private class Geary.ImapEngine.AccountSynchronizer : Geary.BaseObject {
             debug("Error background syncing folder %s: %s", folder.to_string(), err.message);
             
             // fallthrough and close
-        } finally {
-            folder.email_flag_watcher.enabled = true;
         }
         
         try {


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]