From: Claudio Cambra Date: Thu, 27 Jul 2023 08:37:40 +0000 (+0800) Subject: Clean up declaration of propagateuploadng X-Git-Tag: archive/raspbian/3.16.7-1_deb13u1+rpi1~1^2~12^2~9^2~24^2~14 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=12827d1746bfcc3451d18d64e77f84276a5c3c3e;p=nextcloud-desktop.git Clean up declaration of propagateuploadng Signed-off-by: Claudio Cambra --- diff --git a/src/libsync/propagateupload.h b/src/libsync/propagateupload.h index 10f42ddc8..914ad24f1 100644 --- a/src/libsync/propagateupload.h +++ b/src/libsync/propagateupload.h @@ -378,27 +378,6 @@ private slots: class PropagateUploadFileNG : public PropagateUploadFileCommon { Q_OBJECT -private: - qint64 _sent = 0; /// amount of data (bytes) that was already sent - uint _transferId = 0; /// transfer id (part of the url) - int _currentChunk = 0; /// Id of the next chunk that will be sent - qint64 _currentChunkSize = 0; /// current chunk size - bool _removeJobError = false; /// If not null, there was an error removing the job - - // Map chunk number with its size from the PROPFIND on resume. - // (Only used from slotPropfindIterate/slotPropfindFinished because the LsColJob use signals to report data.) - struct ServerChunkInfo - { - qint64 size = 0LL; - QString originalName; - }; - QMap _serverChunks; - - /** - * Return the URL of a chunk. - * If chunk == -1, returns the URL of the parent folder containing the chunks - */ - QUrl chunkUrl(int chunk = -1); public: PropagateUploadFileNG(OwncloudPropagator *propagator, const SyncFileItemPtr &item) @@ -408,11 +387,6 @@ public: void doStartUpload() override; -private: - void startNewUpload(); - void startNextChunk(); - void finishUpload(); - public slots: void abort(OCC::PropagateUploadFileNG::AbortType abortType) override; @@ -425,5 +399,31 @@ private slots: void slotPutFinished(); void slotMoveJobFinished(); void slotUploadProgress(qint64, qint64); + +private: + // Map chunk number with its size from the PROPFIND on resume. + // (Only used from slotPropfindIterate/slotPropfindFinished because the LsColJob use signals to report data.) + struct ServerChunkInfo { + qint64 size = 0LL; + QString originalName; + }; + + /** + * Return the URL of a chunk. + * If chunk == -1, returns the URL of the parent folder containing the chunks + */ + QUrl chunkUrl(int chunk = -1); + + void startNewUpload(); + void startNextChunk(); + void finishUpload(); + + QMap _serverChunks; + + qint64 _sent = 0; /// amount of data (bytes) that was already sent + uint _transferId = 0; /// transfer id (part of the url) + int _currentChunk = 0; /// Id of the next chunk that will be sent + qint64 _currentChunkSize = 0; /// current chunk size + bool _removeJobError = false; /// If not null, there was an error removing the job }; }