Changeset 2789


Ignore:
Timestamp:
7/31/2012 9:26:04 AM (2 years ago)
Author:
lowjoel
Message:

Do not trigger a GUI update so often -- this caused compression times to be excessively long. Addresses #448

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/eraser/Eraser.BlackBox/BlackBoxReportUploader.cs

    r2715 r2789  
    5858                StepProgress = stepProgress; 
    5959                EventHandler = progressChanged; 
     60                LastProgressReport = DateTime.MinValue; 
    6061            } 
    6162 
     
    6465            public void SetProgress(long inSize, long outSize) 
    6566            { 
    66                 StepProgress.Completed = inSize; 
    67                 EventHandler(Uploader, new ProgressChangedEventArgs(Progress, null)); 
     67                if ((DateTime.Now - LastProgressReport).Ticks > TimeSpan.TicksPerSecond) 
     68                { 
     69                    StepProgress.Completed = inSize; 
     70                    EventHandler(Uploader, new ProgressChangedEventArgs(Progress, null)); 
     71                    LastProgressReport = DateTime.Now; 
     72                } 
    6873            } 
    6974 
     
    7479            private ProgressManager StepProgress; 
    7580            private ProgressChangedEventHandler EventHandler; 
     81 
     82            private DateTime LastProgressReport; 
    7683        } 
    7784 
     
    339346        /// </summary> 
    340347        private static readonly Uri BlackBoxServer = 
    341             new Uri("http://eraser.heidi.ie/scripts/blackbox/upload.php"); 
     348            new Uri("http://eraser.clients.bookmarkconsultants.com/scripts/blackbox/upload.php"); 
    342349 
    343350        /// <summary> 
Note: See TracChangeset for help on using the changeset viewer.