aboutsummaryrefslogtreecommitdiff
path: root/backends/cloud/onedrive
diff options
context:
space:
mode:
authorAlexander Tkachev2016-06-21 17:07:23 +0600
committerAlexander Tkachev2016-08-24 16:07:55 +0600
commitf3a392359be2f6d05bac107a5f7bd168c178e428 (patch)
treeeab864e98d1b75414f55053375fab076e1b23ecc /backends/cloud/onedrive
parentfa3ea83165d6c378348f61f8daec85f805626dbe (diff)
downloadscummvm-rg350-f3a392359be2f6d05bac107a5f7bd168c178e428.tar.gz
scummvm-rg350-f3a392359be2f6d05bac107a5f7bd168c178e428.tar.bz2
scummvm-rg350-f3a392359be2f6d05bac107a5f7bd168c178e428.zip
CLOUD: Fix finishSuccess() warning
Diffstat (limited to 'backends/cloud/onedrive')
-rw-r--r--backends/cloud/onedrive/onedrivecreatedirectoryrequest.cpp4
-rw-r--r--backends/cloud/onedrive/onedrivecreatedirectoryrequest.h2
-rw-r--r--backends/cloud/onedrive/onedrivelistdirectoryrequest.cpp4
-rw-r--r--backends/cloud/onedrive/onedrivelistdirectoryrequest.h2
-rw-r--r--backends/cloud/onedrive/onedrivetokenrefresher.cpp6
-rw-r--r--backends/cloud/onedrive/onedrivetokenrefresher.h2
-rw-r--r--backends/cloud/onedrive/onedriveuploadrequest.cpp6
-rw-r--r--backends/cloud/onedrive/onedriveuploadrequest.h2
8 files changed, 14 insertions, 14 deletions
diff --git a/backends/cloud/onedrive/onedrivecreatedirectoryrequest.cpp b/backends/cloud/onedrive/onedrivecreatedirectoryrequest.cpp
index 2c644c42c5..617346529b 100644
--- a/backends/cloud/onedrive/onedrivecreatedirectoryrequest.cpp
+++ b/backends/cloud/onedrive/onedrivecreatedirectoryrequest.cpp
@@ -101,7 +101,7 @@ void OneDriveCreateDirectoryRequest::responseCallback(Networking::JsonResponse r
}
Common::JSONObject info = json->asObject();
- if (info.contains("id")) finishSuccess(true);
+ if (info.contains("id")) finishCreation(true);
else {
error.response = json->stringify(true);
finishError(error);
@@ -123,7 +123,7 @@ void OneDriveCreateDirectoryRequest::restart() { start(); }
Common::String OneDriveCreateDirectoryRequest::date() const { return _date; }
-void OneDriveCreateDirectoryRequest::finishSuccess(bool success) {
+void OneDriveCreateDirectoryRequest::finishCreation(bool success) {
Request::finishSuccess();
if (_boolCallback) (*_boolCallback)(Storage::BoolResponse(this, success));
}
diff --git a/backends/cloud/onedrive/onedrivecreatedirectoryrequest.h b/backends/cloud/onedrive/onedrivecreatedirectoryrequest.h
index 880e94e8db..83c72c4e0a 100644
--- a/backends/cloud/onedrive/onedrivecreatedirectoryrequest.h
+++ b/backends/cloud/onedrive/onedrivecreatedirectoryrequest.h
@@ -43,7 +43,7 @@ class OneDriveCreateDirectoryRequest: public Networking::Request {
void start();
void responseCallback(Networking::JsonResponse response);
void errorCallback(Networking::ErrorResponse error);
- void finishSuccess(bool success);
+ void finishCreation(bool success);
public:
OneDriveCreateDirectoryRequest(OneDriveStorage *storage, Common::String path, Storage::BoolCallback cb, Networking::ErrorCallback ecb);
virtual ~OneDriveCreateDirectoryRequest();
diff --git a/backends/cloud/onedrive/onedrivelistdirectoryrequest.cpp b/backends/cloud/onedrive/onedrivelistdirectoryrequest.cpp
index be6fcb70e7..baccdf418e 100644
--- a/backends/cloud/onedrive/onedrivelistdirectoryrequest.cpp
+++ b/backends/cloud/onedrive/onedrivelistdirectoryrequest.cpp
@@ -60,7 +60,7 @@ void OneDriveListDirectoryRequest::start() {
void OneDriveListDirectoryRequest::listNextDirectory() {
if (_directoriesQueue.empty()) {
- finishSuccess(_files);
+ finishListing(_files);
return;
}
@@ -150,7 +150,7 @@ void OneDriveListDirectoryRequest::restart() { start(); }
Common::String OneDriveListDirectoryRequest::date() const { return _date; }
-void OneDriveListDirectoryRequest::finishSuccess(Common::Array<StorageFile> &files) {
+void OneDriveListDirectoryRequest::finishListing(Common::Array<StorageFile> &files) {
Request::finishSuccess();
if (_listDirectoryCallback) (*_listDirectoryCallback)(Storage::ListDirectoryResponse(this, files));
}
diff --git a/backends/cloud/onedrive/onedrivelistdirectoryrequest.h b/backends/cloud/onedrive/onedrivelistdirectoryrequest.h
index 5e80f4f561..eb510ab257 100644
--- a/backends/cloud/onedrive/onedrivelistdirectoryrequest.h
+++ b/backends/cloud/onedrive/onedrivelistdirectoryrequest.h
@@ -50,7 +50,7 @@ class OneDriveListDirectoryRequest: public Networking::Request {
void listedDirectoryCallback(Networking::JsonResponse response);
void listedDirectoryErrorCallback(Networking::ErrorResponse error);
void makeRequest(Common::String url);
- void finishSuccess(Common::Array<StorageFile> &files);
+ void finishListing(Common::Array<StorageFile> &files);
public:
OneDriveListDirectoryRequest(OneDriveStorage *storage, Common::String path, Storage::ListDirectoryCallback cb, Networking::ErrorCallback ecb, bool recursive = false);
virtual ~OneDriveListDirectoryRequest();
diff --git a/backends/cloud/onedrive/onedrivetokenrefresher.cpp b/backends/cloud/onedrive/onedrivetokenrefresher.cpp
index bf849f7964..04e155c084 100644
--- a/backends/cloud/onedrive/onedrivetokenrefresher.cpp
+++ b/backends/cloud/onedrive/onedrivetokenrefresher.cpp
@@ -56,10 +56,10 @@ void OneDriveTokenRefresher::tokenRefreshed(Storage::BoolResponse response) {
retry(0);
}
-void OneDriveTokenRefresher::finishSuccess(Common::JSONValue *json) {
+void OneDriveTokenRefresher::finishJson(Common::JSONValue *json) {
if (!json) {
//that's probably not an error (200 OK)
- CurlJsonRequest::finishSuccess(nullptr);
+ CurlJsonRequest::finishJson(nullptr);
return;
}
@@ -105,7 +105,7 @@ void OneDriveTokenRefresher::finishSuccess(Common::JSONValue *json) {
}
//notify user of success
- CurlJsonRequest::finishSuccess(json);
+ CurlJsonRequest::finishJson(json);
}
void OneDriveTokenRefresher::setHeaders(Common::Array<Common::String> &headers) {
diff --git a/backends/cloud/onedrive/onedrivetokenrefresher.h b/backends/cloud/onedrive/onedrivetokenrefresher.h
index 04b0bf26b8..4be1fa726b 100644
--- a/backends/cloud/onedrive/onedrivetokenrefresher.h
+++ b/backends/cloud/onedrive/onedrivetokenrefresher.h
@@ -37,7 +37,7 @@ class OneDriveTokenRefresher: public Networking::CurlJsonRequest {
void tokenRefreshed(Storage::BoolResponse response);
- virtual void finishSuccess(Common::JSONValue *json);
+ virtual void finishJson(Common::JSONValue *json);
public:
OneDriveTokenRefresher(OneDriveStorage *parent, Networking::JsonCallback callback, Networking::ErrorCallback ecb, const char *url);
virtual ~OneDriveTokenRefresher();
diff --git a/backends/cloud/onedrive/onedriveuploadrequest.cpp b/backends/cloud/onedrive/onedriveuploadrequest.cpp
index 08f45935d2..fb32443a27 100644
--- a/backends/cloud/onedrive/onedriveuploadrequest.cpp
+++ b/backends/cloud/onedrive/onedriveuploadrequest.cpp
@@ -126,7 +126,7 @@ void OneDriveUploadRequest::partUploadedCallback(Networking::JsonResponse respon
Common::String path = _savePath; //object.getVal("name")->asString();; //object.getVal("id")->asString();
uint32 size = object.getVal("size")->asIntegerNumber();
uint32 timestamp = ISO8601::convertToTimestamp(object.getVal("lastModifiedDateTime")->asString());
- finishSuccess(StorageFile(path, size, timestamp, false));
+ finishUpload(StorageFile(path, size, timestamp, false));
return;
}
@@ -140,7 +140,7 @@ void OneDriveUploadRequest::partUploadedCallback(Networking::JsonResponse respon
if (_contentsStream->eos() || _contentsStream->pos() >= _contentsStream->size() - 1) {
warning("no file info to return");
- finishSuccess(StorageFile(_savePath, 0, 0, false));
+ finishUpload(StorageFile(_savePath, 0, 0, false));
} else {
uploadNextPart();
}
@@ -162,7 +162,7 @@ void OneDriveUploadRequest::handle() {}
void OneDriveUploadRequest::restart() { start(); }
-void OneDriveUploadRequest::finishSuccess(StorageFile file) {
+void OneDriveUploadRequest::finishUpload(StorageFile file) {
Request::finishSuccess();
if (_uploadCallback) (*_uploadCallback)(Storage::UploadResponse(this, file));
}
diff --git a/backends/cloud/onedrive/onedriveuploadrequest.h b/backends/cloud/onedrive/onedriveuploadrequest.h
index 09419d8a15..f613c415e1 100644
--- a/backends/cloud/onedrive/onedriveuploadrequest.h
+++ b/backends/cloud/onedrive/onedriveuploadrequest.h
@@ -45,7 +45,7 @@ class OneDriveUploadRequest: public Networking::Request {
void uploadNextPart();
void partUploadedCallback(Networking::JsonResponse response);
void partUploadedErrorCallback(Networking::ErrorResponse error);
- void finishSuccess(StorageFile status);
+ void finishUpload(StorageFile status);
public:
OneDriveUploadRequest(OneDriveStorage *storage, Common::String path, Common::SeekableReadStream *contents, Storage::UploadCallback callback, Networking::ErrorCallback ecb);