mirror of
https://github.com/nextcloud/desktop.git
synced 2026-01-14 02:01:28 +00:00
chore: fix unity build for AppImage
Signed-off-by: Matthieu Gallien <matthieu.gallien@nextcloud.com>
This commit is contained in:
@ -4,6 +4,8 @@
|
|||||||
* SPDX-License-Identifier: GPL-2.0-or-later
|
* SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
#include <QObject>
|
#include <QObject>
|
||||||
#include <QPoint>
|
#include <QPoint>
|
||||||
|
|
||||||
|
|||||||
@ -30,7 +30,7 @@ BulkPropagatorDownloadJob::BulkPropagatorDownloadJob(OwncloudPropagator *propaga
|
|||||||
|
|
||||||
namespace
|
namespace
|
||||||
{
|
{
|
||||||
static QString makeRecallFileName(const QString &fn)
|
static QString makeBulkDownloadRecallFileName(const QString &fn)
|
||||||
{
|
{
|
||||||
auto recallFileName(fn);
|
auto recallFileName(fn);
|
||||||
// Add _recall-XXXX before the extension.
|
// Add _recall-XXXX before the extension.
|
||||||
@ -46,9 +46,9 @@ static QString makeRecallFileName(const QString &fn)
|
|||||||
return recallFileName;
|
return recallFileName;
|
||||||
}
|
}
|
||||||
|
|
||||||
void handleRecallFile(const QString &filePath, const QString &folderPath, SyncJournalDb &journal)
|
void handleBulkDownloadRecallFile(const QString &filePath, const QString &folderPath, SyncJournalDb &journal)
|
||||||
{
|
{
|
||||||
qCDebug(lcBulkPropagatorDownloadJob) << "handleRecallFile: " << filePath;
|
qCDebug(lcBulkPropagatorDownloadJob) << "handleBulkDownloadRecallFile: " << filePath;
|
||||||
|
|
||||||
FileSystem::setFileHidden(filePath, true);
|
FileSystem::setFileHidden(filePath, true);
|
||||||
|
|
||||||
@ -81,7 +81,7 @@ void handleRecallFile(const QString &filePath, const QString &folderPath, SyncJo
|
|||||||
|
|
||||||
qCInfo(lcBulkPropagatorDownloadJob) << "Recalling" << localRecalledFile << "Checksum:" << record._checksumHeader;
|
qCInfo(lcBulkPropagatorDownloadJob) << "Recalling" << localRecalledFile << "Checksum:" << record._checksumHeader;
|
||||||
|
|
||||||
const auto &targetPath = makeRecallFileName(recalledFile);
|
const auto &targetPath = makeBulkDownloadRecallFileName(recalledFile);
|
||||||
|
|
||||||
qCDebug(lcBulkPropagatorDownloadJob) << "Copy recall file: " << recalledFile << " -> " << targetPath;
|
qCDebug(lcBulkPropagatorDownloadJob) << "Copy recall file: " << recalledFile << " -> " << targetPath;
|
||||||
// Remove the target first, QFile::copy will not overwrite it.
|
// Remove the target first, QFile::copy will not overwrite it.
|
||||||
@ -197,7 +197,7 @@ bool BulkPropagatorDownloadJob::updateMetadata(const SyncFileItemPtr &item)
|
|||||||
// handle the special recall file
|
// handle the special recall file
|
||||||
if (!item->_remotePerm.hasPermission(RemotePermissions::IsShared)
|
if (!item->_remotePerm.hasPermission(RemotePermissions::IsShared)
|
||||||
&& (item->_file == QLatin1String(".sys.admin#recall#") || item->_file.endsWith(QLatin1String("/.sys.admin#recall#")))) {
|
&& (item->_file == QLatin1String(".sys.admin#recall#") || item->_file.endsWith(QLatin1String("/.sys.admin#recall#")))) {
|
||||||
handleRecallFile(fullFileName, propagator()->localPath(), *propagator()->_journal);
|
handleBulkDownloadRecallFile(fullFileName, propagator()->localPath(), *propagator()->_journal);
|
||||||
}
|
}
|
||||||
|
|
||||||
const auto isLockOwnedByCurrentUser = item->_lockOwnerId == propagator()->account()->davUser();
|
const auto isLockOwnedByCurrentUser = item->_lockOwnerId == propagator()->account()->davUser();
|
||||||
|
|||||||
Reference in New Issue
Block a user