diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-05-21 12:28:40 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-05-21 20:26:12 +0300 |
commit | f4fe732ccbd65fd584b7787f3b5aec904a85d11b (patch) | |
tree | 5cf6023ab3713316326547026c10f2fb4ce6d8b8 /src/net/download.cpp | |
parent | c78423448941517eeae0a60e703a5dc2976aed0c (diff) | |
download | manaplus-f4fe732ccbd65fd584b7787f3b5aec904a85d11b.tar.gz manaplus-f4fe732ccbd65fd584b7787f3b5aec904a85d11b.tar.bz2 manaplus-f4fe732ccbd65fd584b7787f3b5aec904a85d11b.tar.xz manaplus-f4fe732ccbd65fd584b7787f3b5aec904a85d11b.zip |
Fix code style.
Diffstat (limited to 'src/net/download.cpp')
-rw-r--r-- | src/net/download.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/net/download.cpp b/src/net/download.cpp index c61e42e0c..011182a7e 100644 --- a/src/net/download.cpp +++ b/src/net/download.cpp @@ -202,7 +202,7 @@ bool Download::start() logger->log1(DOWNLOAD_ERROR_MESSAGE_THREAD); if (mError) strcpy(mError, DOWNLOAD_ERROR_MESSAGE_THREAD); - mUpdateFunction(mPtr, DownloadStatus::THREAD_ERROR, 0, 0); + mUpdateFunction(mPtr, DownloadStatus::ThreadError, 0, 0); if (!mIgnoreError) return false; } @@ -239,12 +239,12 @@ int Download::downloadProgress(void *clientp, double dltotal, double dlnow, if (d->mOptions.cancel) { - return d->mUpdateFunction(d->mPtr, DownloadStatus::CANCELLED, + return d->mUpdateFunction(d->mPtr, DownloadStatus::Cancelled, static_cast<size_t>(dltotal), static_cast<size_t>(dlnow)); } - return d->mUpdateFunction(d->mPtr, DownloadStatus::IDLE, + return d->mUpdateFunction(d->mPtr, DownloadStatus::Idle, static_cast<size_t>(dltotal), static_cast<size_t>(dlnow)); } @@ -283,7 +283,7 @@ int Download::downloadThread(void *ptr) logger->log_r("selected url: %s", d->mUrl.c_str()); while (attempts < 3 && !complete && !d->mOptions.cancel) { - d->mUpdateFunction(d->mPtr, DownloadStatus::STARTING, 0, 0); + d->mUpdateFunction(d->mPtr, DownloadStatus::Starting, 0, 0); if (d->mOptions.cancel) { @@ -372,7 +372,7 @@ int Download::downloadThread(void *ptr) if (d->mOptions.cancel) break; -// d->mUpdateFunction(d->mPtr, DownloadStatus::ERROR, 0, 0); +// d->mUpdateFunction(d->mPtr, DownloadStatus::Error, 0, 0); if (file) { @@ -495,11 +495,11 @@ int Download::downloadThread(void *ptr) } else if (!complete || attempts >= 3) { - d->mUpdateFunction(d->mPtr, DownloadStatus::ERROR, 0, 0); + d->mUpdateFunction(d->mPtr, DownloadStatus::Error, 0, 0); } else { - d->mUpdateFunction(d->mPtr, DownloadStatus::COMPLETE, 0, 0); + d->mUpdateFunction(d->mPtr, DownloadStatus::Complete, 0, 0); } return 0; |