diff options
author | Alexander Tkachev | 2016-05-27 15:21:06 +0600 |
---|---|---|
committer | Alexander Tkachev | 2016-08-24 16:07:55 +0600 |
commit | 98150beb38f73b56c7bc76f95dcc1d72290e4ac7 (patch) | |
tree | c56f8d97d30fb15f41f07f402c80e83a13cc03fc /backends/cloud/dropbox/dropboxlistdirectoryrequest.h | |
parent | 83b349a033d71e92e292d1f1da0578d557ec6411 (diff) | |
download | scummvm-rg350-98150beb38f73b56c7bc76f95dcc1d72290e4ac7.tar.gz scummvm-rg350-98150beb38f73b56c7bc76f95dcc1d72290e4ac7.tar.bz2 scummvm-rg350-98150beb38f73b56c7bc76f95dcc1d72290e4ac7.zip |
CLOUD: Refactor ConnectionManager/Requests system
ConnectionManager now storages Request * (not generates ids for it),
Requests have control on their RequestState, RequestIdPair is now called
Response and storages Request * with some response together.
All related classes are changed to use it in more clean and
understandable way.
Request, RequestState and Response are carefully commented/documented.
Diffstat (limited to 'backends/cloud/dropbox/dropboxlistdirectoryrequest.h')
-rw-r--r-- | backends/cloud/dropbox/dropboxlistdirectoryrequest.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/backends/cloud/dropbox/dropboxlistdirectoryrequest.h b/backends/cloud/dropbox/dropboxlistdirectoryrequest.h index 9a82ef7091..e2a9ebf3a4 100644 --- a/backends/cloud/dropbox/dropboxlistdirectoryrequest.h +++ b/backends/cloud/dropbox/dropboxlistdirectoryrequest.h @@ -39,17 +39,20 @@ class DropboxListDirectoryRequest: public Networking::Request { Common::String _token; bool _complete; Common::Array<StorageFile> _files; - int32 _requestId; + Request *_innerRequest; - void responseCallback(Networking::RequestJsonPair pair); + void responseCallback(Networking::JsonResponse pair); void startupWork(); + void finishFiles(Common::Array<StorageFile> &files); + public: DropboxListDirectoryRequest(Common::String token, Common::String path, Storage::FileArrayCallback cb, bool recursive = false); virtual ~DropboxListDirectoryRequest() { delete _filesCallback; } virtual void handle(); virtual void restart(); + virtual void finish(); }; } //end of namespace Dropbox |