Add setIsLivePhoto method to FileInfo

Signed-off-by: Claudio Cambra <claudio.cambra@nextcloud.com>
This commit is contained in:
Claudio Cambra 2024-10-30 12:16:44 +08:00 коммит произвёл Matthieu Gallien
Родитель 74651a0ca8
Коммит ed71524aeb
2 изменённых файлов: 9 добавлений и 0 удалений

Просмотреть файл

@ -223,6 +223,13 @@ void FileInfo::setModTimeKeepEtag(const QString &relativePath, const QDateTime &
file->lastModified = modTime; file->lastModified = modTime;
} }
void FileInfo::setIsLivePhoto(const QString &relativePath, const bool isLivePhoto)
{
const auto file = find(relativePath);
Q_ASSERT(file);
file->isLivePhoto = isLivePhoto;
}
void FileInfo::modifyLockState(const QString &relativePath, LockState lockState, int lockType, const QString &lockOwner, const QString &lockOwnerId, const QString &lockEditorId, quint64 lockTime, quint64 lockTimeout) void FileInfo::modifyLockState(const QString &relativePath, LockState lockState, int lockType, const QString &lockOwner, const QString &lockOwnerId, const QString &lockEditorId, quint64 lockTime, quint64 lockTimeout)
{ {
FileInfo *file = findInvalidatingEtags(relativePath); FileInfo *file = findInvalidatingEtags(relativePath);

Просмотреть файл

@ -142,6 +142,8 @@ public:
void setModTimeKeepEtag(const QString &relativePath, const QDateTime &modTime); void setModTimeKeepEtag(const QString &relativePath, const QDateTime &modTime);
void setIsLivePhoto(const QString &relativePath, bool isLivePhoto);
void modifyLockState(const QString &relativePath, LockState lockState, int lockType, const QString &lockOwner, const QString &lockOwnerId, const QString &lockEditorId, quint64 lockTime, quint64 lockTimeout) override; void modifyLockState(const QString &relativePath, LockState lockState, int lockType, const QString &lockOwner, const QString &lockOwnerId, const QString &lockEditorId, quint64 lockTime, quint64 lockTimeout) override;
void setE2EE(const QString &relativepath, const bool enabled) override; void setE2EE(const QString &relativepath, const bool enabled) override;