Add starter FileProviderEditLocally class
authorClaudio Cambra <claudio.cambra@nextcloud.com>
Tue, 28 May 2024 08:03:19 +0000 (16:03 +0800)
committerClaudio Cambra <claudio.cambra@nextcloud.com>
Mon, 22 Jul 2024 11:51:38 +0000 (19:51 +0800)
Signed-off-by: Claudio Cambra <claudio.cambra@nextcloud.com>
src/gui/CMakeLists.txt
src/gui/macOS/fileprovidereditlocallyjob.cpp [new file with mode: 0644]
src/gui/macOS/fileprovidereditlocallyjob.h [new file with mode: 0644]

index fde6ac4a0d10dbc734cf133a556bab767f86c674..8cf5eb98166e89fd00564f5197d897fec8098b5f 100644 (file)
@@ -290,6 +290,8 @@ IF( APPLE )
             macOS/fileproviderdomainmanager_mac.mm
             macOS/fileproviderdomainsyncstatus.h
             macOS/fileproviderdomainsyncstatus_mac.mm
+            macOS/fileprovidereditlocallyjob.h
+            macOS/fileprovidereditlocallyjob.cpp
             macOS/fileprovideritemmetadata.h
             macOS/fileprovideritemmetadata.cpp
             macOS/fileprovideritemmetadata_mac.mm
diff --git a/src/gui/macOS/fileprovidereditlocallyjob.cpp b/src/gui/macOS/fileprovidereditlocallyjob.cpp
new file mode 100644 (file)
index 0000000..97a0897
--- /dev/null
@@ -0,0 +1,32 @@
+/*
+ * Copyright (C) by Claudio Cambra <claudio.cambra@nextcloud.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+ * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * for more details.
+ */
+
+#include "fileprovidereditlocallyjob.h"
+
+#include <QLoggingCategory>
+
+namespace OCC::Mac {
+
+Q_LOGGING_CATEGORY(lcFileProviderEditLocallyJob, "nextcloud.gui.fileprovidereditlocally", QtInfoMsg)
+
+FileProviderEditLocallyJob::FileProviderEditLocallyJob(const AccountStatePtr &accountState,
+                                                       const QString &relPath,
+                                                       QObject *const parent)
+    : QObject(parent)
+    , _accountState(accountState)
+    , _relPath(relPath)
+{
+}
+
+} // namespace OCC::Mac
diff --git a/src/gui/macOS/fileprovidereditlocallyjob.h b/src/gui/macOS/fileprovidereditlocallyjob.h
new file mode 100644 (file)
index 0000000..5c0c9d8
--- /dev/null
@@ -0,0 +1,38 @@
+/*
+ * Copyright (C) by Claudio Cambra <claudio.cambra@nextcloud.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+ * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+ * for more details.
+ */
+
+#pragma once
+
+#include <QObject>
+#include <QString>
+
+#include "accountstate.h"
+
+namespace OCC::Mac {
+
+class FileProviderEditLocallyJob : public QObject
+{
+    Q_OBJECT
+
+public:
+    explicit FileProviderEditLocallyJob(const AccountStatePtr &accountState,
+                                        const QString &relPath,
+                                        QObject * const parent = nullptr);
+
+private:
+    AccountStatePtr _accountState;
+    QString _relPath;
+};
+
+}