mirror of
https://github.com/HeidiSQL/HeidiSQL.git
synced 2025-08-26 22:00:16 +08:00
Updatecheck: Fix displaying the correct filesize of a nightly build while downloading. Read it from the checkfile. The server doesn't include the filesize in the header any longer.
This commit is contained in:
@ -39,6 +39,7 @@ type
|
|||||||
AutoClose: Boolean; // Automatically close dialog after detecting no available downloads
|
AutoClose: Boolean; // Automatically close dialog after detecting no available downloads
|
||||||
CurrentRevision: Integer;
|
CurrentRevision: Integer;
|
||||||
CheckForBuildsInAutoMode: Boolean;
|
CheckForBuildsInAutoMode: Boolean;
|
||||||
|
BuildSize: Integer;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
implementation
|
implementation
|
||||||
@ -192,6 +193,7 @@ begin
|
|||||||
if Ini.SectionExists(INISECT_BUILD) then begin
|
if Ini.SectionExists(INISECT_BUILD) then begin
|
||||||
BuildRevision := Ini.ReadInteger(INISECT_BUILD, 'Revision', 0);
|
BuildRevision := Ini.ReadInteger(INISECT_BUILD, 'Revision', 0);
|
||||||
BuildURL := Ini.ReadString(INISECT_BUILD, 'URL', '');
|
BuildURL := Ini.ReadString(INISECT_BUILD, 'URL', '');
|
||||||
|
BuildSize := Ini.ReadInteger(INISECT_BUILD, 'Size', 0);
|
||||||
memoBuild.Lines.Add( 'Revision ' + IntToStr(BuildRevision) + ' (yours: '+AppRevision+')' );
|
memoBuild.Lines.Add( 'Revision ' + IntToStr(BuildRevision) + ' (yours: '+AppRevision+')' );
|
||||||
FileAge(ParamStr(0), Compiled);
|
FileAge(ParamStr(0), Compiled);
|
||||||
memoBuild.Lines.Add( 'Compiled: ' + Ini.ReadString(INISECT_BUILD, 'Date', '') + ' (yours: '+DateToStr(Compiled)+')' );
|
memoBuild.Lines.Add( 'Compiled: ' + Ini.ReadString(INISECT_BUILD, 'Date', '') + ' (yours: '+DateToStr(Compiled)+')' );
|
||||||
@ -312,7 +314,7 @@ end;
|
|||||||
}
|
}
|
||||||
procedure TfrmUpdateCheck.URLOnDownloadProgress;
|
procedure TfrmUpdateCheck.URLOnDownloadProgress;
|
||||||
begin
|
begin
|
||||||
Status('Downloading: '+FormatByteNumber(Progress)+' / '+FormatByteNumber(ProgressMax) + ' ...');
|
Status('Downloading: '+FormatByteNumber(Progress)+' / '+FormatByteNumber(BuildSize) + ' ...');
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user