Merge branch 'master' into jgrpp-beta

This commit is contained in:
Jonathan G Rennison
2021-10-29 17:56:32 +01:00
4 changed files with 6 additions and 6 deletions

View File

@@ -130,7 +130,7 @@ void BaseNetworkContentDownloadStatusWindow::DrawWidget(const Rect &r, int widge
StringID str;
if (this->downloaded_bytes == this->total_bytes) {
str = STR_CONTENT_DOWNLOAD_COMPLETE;
} else if (!StrEmpty(this->name)) {
} else if (!this->name.empty()) {
SetDParamStr(0, this->name);
SetDParam(1, this->downloaded_files);
SetDParam(2, this->total_files);
@@ -146,7 +146,7 @@ void BaseNetworkContentDownloadStatusWindow::DrawWidget(const Rect &r, int widge
void BaseNetworkContentDownloadStatusWindow::OnDownloadProgress(const ContentInfo *ci, int bytes)
{
if (ci->id != this->cur_id) {
strecpy(this->name, ci->filename.c_str(), lastof(this->name));
this->name = ci->filename;
this->cur_id = ci->id;
this->downloaded_files++;
}