Bladeren bron

Collection time (addition to 7b2f2ec2e)

Source commit: b4fa9261df1bb288aa1dfcfbb6ef3a17b8bb3ae6
Martin Prikryl 7 jaren geleden
bovenliggende
commit
5097d36e01
2 gewijzigde bestanden met toevoegingen van 7 en 2 verwijderingen
  1. 6 1
      source/forms/CustomScpExplorer.cpp
  2. 1 1
      source/resource/TextsWin1.rc

+ 6 - 1
source/forms/CustomScpExplorer.cpp

@@ -5400,6 +5400,7 @@ struct TSynchronizeParams
   TSynchronizeChecklist * Checklist;
   int Params;
   TCopyParamType * CopyParam;
+  TDateTime CollectElapsed;
   TDateTime * StartTime;
   TProcessedSynchronizationChecklistItem OnProcessedItem;
 };
@@ -5464,7 +5465,10 @@ void __fastcall TCustomScpExplorerForm::FullSynchronize(
     }
 
     TDateTime Elapsed = (Now() - Start);
-    Message += L"\n" + FORMAT(LoadStrPart(SYNCHRONIZE_SUMMARY, 5), (FormatDateTimeSpan(Configuration->TimeFormat, Elapsed)));
+    Message +=
+      L"\n" +
+      FORMAT(LoadStrPart(SYNCHRONIZE_SUMMARY, 5), (FormatDateTimeSpan(Configuration->TimeFormat, Params.CollectElapsed))) + L"\n" +
+      FORMAT(LoadStrPart(SYNCHRONIZE_SUMMARY, 6), (FormatDateTimeSpan(Configuration->TimeFormat, Elapsed)));
     TMessageParams Params(mpNeverAskAgainCheck);
     unsigned int Result = MessageDialog(Message, qtInformation, qaOK, HELP_NONE, &Params);
     if (Result == qaNeverAskAgain)
@@ -5577,6 +5581,7 @@ int __fastcall TCustomScpExplorerForm::DoFullSynchronizeDirectories(
       SynchronizeParams.CopyParam = &CopyParam;
       SynchronizeParams.Params = Params;
       SynchronizeParams.Checklist = Checklist;
+      SynchronizeParams.CollectElapsed = (Now() - StartTime);
       SynchronizeParams.StartTime = &StartTime;
       SynchronizeParams.OnProcessedItem = NULL;
       Result = Checklist->Count;

+ 1 - 1
source/resource/TextsWin1.rc

@@ -619,7 +619,7 @@ BEGIN
         RENAME_SESSION_TITLE, "Rename session"
         RENAME_SESSION_PROMPT, "&New session name:"
         SYNCHRONIZE_COMPLETE, "Synchronization was completed."
-        SYNCHRONIZE_SUMMARY, "Files uploaded: %s (%s)|Files downloaded: %s (%s)|Local files deleted: %s|Remote files deleted: %s|Total time: %s"
+        SYNCHRONIZE_SUMMARY, "Files uploaded: %s (%s)|Files downloaded: %s (%s)|Local files deleted: %s|Remote files deleted: %s|Comparison time: %s|Synchronization time: %s"
 
         WIN_VARIABLE_STRINGS, "WIN_VARIABLE"
         WINSCP_COPYRIGHT, "Copyright © 2000-2018 Martin Prikryl"