Acquire upload/download progress in domain sync status

Signed-off-by: Claudio Cambra <claudio.cambra@nextcloud.com>
This commit is contained in:
Claudio Cambra 2024-01-10 00:16:15 +08:00
parent 6fa969d8f2
commit e314fd05e7
No known key found for this signature in database
GPG key ID: C839200C384636B0

View file

@ -36,7 +36,11 @@ public:
if (_manager == nil) {
qCWarning(lcMacFileProviderDomainSyncStatus) << "Could not get manager for domain" << domainIdentifier;
return;
}
_downloadProgress = [_manager globalProgressForKind:NSProgressFileOperationKindDownloading];
_uploadProgress = [_manager globalProgressForKind:NSProgressFileOperationKindUploading];
}
~MacImplementation() = default;
@ -44,6 +48,9 @@ public:
private:
NSFileProviderDomain *_domain;
NSFileProviderManager *_manager;
NSProgress *_downloadProgress;
NSProgress *_uploadProgress;
QTimer _timer;
FileProviderDomainSyncStatus *q;
};