Пример #1
0
 public ExtractionProgress(AsyncCallback progressCallback, int totalFileCount)
 {
     _activity        = ExtractionActivity.Initializing;
     _currentFileName = "";
     _callback        = progressCallback;
     _waitSignal      = new ManualResetEvent(false);
     _totalFileCount  = totalFileCount;
     _filesExtracted  = 0;
 }
Пример #2
0
 public ExtractionProgress(AsyncCallback progressCallback, int totalFileCount)
 {
     _activity = ExtractionActivity.Initializing;
     _currentFileName = "";
     _callback = progressCallback;
     _waitSignal = new ManualResetEvent(false);
     _totalFileCount = totalFileCount;
     _filesExtracted = 0;
 }
Пример #3
0
            internal void ReportProgress(ExtractionActivity activity, string currentFileName, int filesExtractedSoFar)
            {
                lock (this)
                {
                    _activity = activity;
                    _currentFileName = currentFileName;
                    _filesExtracted = filesExtractedSoFar;

                    if (this.IsCompleted)
                        _waitSignal.Set();

                    if (_callback != null)
                        _callback(this);
                }
            }
Пример #4
0
            internal void ReportProgress(ExtractionActivity activity, string currentFileName, int filesExtractedSoFar)
            {
                lock (this)
                {
                    _activity        = activity;
                    _currentFileName = currentFileName;
                    _filesExtracted  = filesExtractedSoFar;

                    if (this.IsCompleted)
                    {
                        _waitSignal.Set();
                    }

                    if (_callback != null)
                    {
                        _callback(this);
                    }
                }
            }