Browse Source

Removing unused property

Source commit: d394f959aeba233dde83cd1a771015d5c2b398e9
Martin Prikryl 9 years ago
parent
commit
a359d97d07
2 changed files with 3 additions and 4 deletions
  1. 3 3
      source/core/FileOperationProgress.cpp
  2. 0 1
      source/core/FileOperationProgress.h

+ 3 - 3
source/core/FileOperationProgress.cpp

@@ -44,7 +44,7 @@ void __fastcall TFileOperationProgressType::Clear()
   FFullFileName = L"";
   FDirectory = L"";
   FAsciiTransfer = false;
-  FCount = 0;
+  FCount = -1;
   FFilesFinished = 0;
   FStartTime = Now();
   FSuspended = false;
@@ -159,8 +159,8 @@ void __fastcall TFileOperationProgressType::Resume()
 //---------------------------------------------------------------------------
 int __fastcall TFileOperationProgressType::OperationProgress()
 {
-  DebugAssert(Count);
-  int Result = (FFilesFinished * 100)/Count;
+  DebugAssert(FCount > 0);
+  int Result = (FFilesFinished * 100)/FCount;
   return Result;
 }
 //---------------------------------------------------------------------------

+ 0 - 1
source/core/FileOperationProgress.h

@@ -91,7 +91,6 @@ public:
   __property bool InProgress = { read = FInProgress };
   __property bool FileInProgress = { read = FFileInProgress };
   __property TCancelStatus Cancel = { read = FCancel };
-  __property int Count = { read = FCount };
   // when operation started
   __property TDateTime StartTime = { read = FStartTime };
   // bytes transferred