From 4e7dec550077bc37cf254311aefb621cdeebbdfe Mon Sep 17 00:00:00 2001 From: Alexander Tkachev Date: Tue, 31 May 2016 20:54:41 +0600 Subject: CLOUD: Add DropboxCreateDirectoryRequest Also add CloudManager::testFeature(), because syncSaves() now works fine and I don't want to break it again and again with my testing requests. --- backends/cloud/manager.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'backends/cloud/manager.cpp') diff --git a/backends/cloud/manager.cpp b/backends/cloud/manager.cpp index 2f1533c50d..70f2c3a3ef 100644 --- a/backends/cloud/manager.cpp +++ b/backends/cloud/manager.cpp @@ -25,6 +25,7 @@ #include "backends/cloud/onedrive/onedrivestorage.h" #include "common/config-manager.h" #include "common/random.h" +#include "common/debug.h" namespace Cloud { @@ -110,9 +111,19 @@ Storage *Manager::getCurrentStorage() { return nullptr; } +void Manager::printBool(Storage::BoolResponse response) { + debug("bool = %s", (response.value ? "true" : "false")); +} + void Manager::syncSaves(Storage::BoolCallback callback, Networking::ErrorCallback errorCallback) { Storage *storage = getCurrentStorage(); if (storage) storage->syncSaves(callback, errorCallback); } +void Manager::testFeature() { + Storage *storage = getCurrentStorage(); + if (storage) storage->createDirectory("/remote/sub2/dir", + new Common::Callback(this, &Manager::printBool), nullptr); +} + } // End of namespace Cloud -- cgit v1.2.3