mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-12-16 02:20:30 +01:00
Converter: add a message about time used for the conversion
git-svn-id: trunk@39690 -
This commit is contained in:
parent
62517a1978
commit
47303e1f22
@ -935,6 +935,8 @@ function TConvertDelphiProjPack.Convert: TModalResult;
|
||||
var
|
||||
// The initial unit name cache is done in a thread so that GUI shows at once.
|
||||
CacheUnitsThread: TCacheUnitsThread;
|
||||
StartTime, EndTime: TDateTime;
|
||||
s: string;
|
||||
begin
|
||||
if CompareFileExt(fOrigFilename,'.dproj',false)=0 then begin
|
||||
fErrorMsg:=
|
||||
@ -950,6 +952,7 @@ begin
|
||||
try
|
||||
Result:=fSettings.RunForm(CacheUnitsThread); // Get settings from user.
|
||||
if Result=mrOK then begin
|
||||
StartTime:=Now;
|
||||
// create/open lazarus project or package file
|
||||
fLazPFilename:=fSettings.DelphiToLazFilename(fOrigFilename, fLazPSuffix, false);
|
||||
|
||||
@ -964,6 +967,10 @@ begin
|
||||
|
||||
// Actual conversion.
|
||||
Result:=ConvertSub;
|
||||
EndTime:=Now;
|
||||
s:=FormatDateTime('hh:nn:ss', EndTime-StartTime);
|
||||
if s<>'00:00:00' then
|
||||
IDEMessagesWindow.AddMsg(Format(lisConvDelphiConversionTook, [s]), '', -1)
|
||||
end;
|
||||
except
|
||||
on e: EDelphiConverterError do begin
|
||||
|
||||
@ -5345,6 +5345,7 @@ resourcestring
|
||||
lisConvDelphiReplacedUnitInUsesSection = 'Replaced unit "%s" with "%s" in uses section.';
|
||||
lisConvDelphiRemovedUnitInUsesSection = 'Removed unit "%s" in uses section.';
|
||||
lisConvDelphiUnitsToReplaceIn = 'Units to replace in %s';
|
||||
lisConvDelphiConversionTook = 'Conversion took: %s';
|
||||
lisConvDelphiConversionReady = 'Conversion Ready.';
|
||||
lisConvDelphiConversionAborted = 'Conversion Aborted.';
|
||||
lisConvDelphiBeginCodeToolsFailed = 'BeginCodeTools failed!';
|
||||
|
||||
Loading…
Reference in New Issue
Block a user