]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/views/versioncontrol/kversioncontrolplugin.h
Add clang-format and format code as in Frameworks
[dolphin.git] / src / views / versioncontrol / kversioncontrolplugin.h
index c908be24720288b4837cb4200b72070135df48b0..1a411145284211ef14fb5a30fffc9095d31e727c 100644 (file)
@@ -45,7 +45,6 @@ class KFileItem;
  * - Add the following lines at the top of fileviewsvnplugin.cpp:
  *   <code>
  *   #include <KPluginFactory>
- *   #include <KPluginLoader>
  *   K_PLUGIN_CLASS_WITH_JSON(FileViewSvnPlugin, "fileviewsvnplugin.json")
  *   </code>
  *
@@ -74,8 +73,7 @@ class DOLPHINVCS_EXPORT KVersionControlPlugin : public QObject
     Q_OBJECT
 
 public:
-    enum ItemVersion
-    {
+    enum ItemVersion {
         /** The file is not under version control. */
         UnversionedVersion,
         /**
@@ -132,7 +130,7 @@ public:
         MissingVersion
     };
 
-    KVersionControlPlugin(QObjectparent = nullptr);
+    KVersionControlPlugin(QObject *parent = nullptr);
     ~KVersionControlPlugin() override;
 
     /**
@@ -143,10 +141,10 @@ public:
     virtual QString fileName() const = 0;
 
     /**
-     * Returns the path of the local repository root for the versionned directory
-     * Returns an emtpy QString when directory is not part of a working copy
+     * Returns the path of the local repository root for the versioned directory
+     * Returns an empty QString when directory is not part of a working copy
      */
-    virtual QString localRepositoryRoot(const QStringdirectory) const;
+    virtual QString localRepositoryRoot(const QString &directory) const;
 
     /**
      * Is invoked whenever the version control
@@ -154,7 +152,7 @@ public:
      * \p directory. It is assured that the directory
      * contains a trailing slash.
      */
-    virtual bool beginRetrieval(const QStringdirectory) = 0;
+    virtual bool beginRetrieval(const QString &directory) = 0;
 
     /**
      * Is invoked after the version control information has been
@@ -170,13 +168,13 @@ public:
      *         invoked before and that the file is part of the directory specified
      *         in beginRetrieval().
      */
-    virtual ItemVersion itemVersion(const KFileItemitem) const = 0;
+    virtual ItemVersion itemVersion(const KFileItem &item) const = 0;
 
     /**
      * @return List of actions that are available for the \p items in a version controlled
      *         path.
      */
-    virtual QList<QAction*> versionControlActions(const KFileItemList& items) const = 0;
+    virtual QList<QAction *> versionControlActions(const KFileItemList &items) const = 0;
 
     /**
      * @return List of actions that are available for the out of version control
@@ -184,7 +182,7 @@ public:
      *         is for clone/checkout actions.
      * @since 21.04
      */
-    virtual QList<QAction*> outOfVersionControlActions(const KFileItemList& items) const = 0;
+    virtual QList<QAction *> outOfVersionControlActions(const KFileItemList &items) const = 0;
 
 Q_SIGNALS:
     /**
@@ -202,20 +200,19 @@ Q_SIGNALS:
      * Is emitted if an information message with the content \a msg
      * should be shown.
      */
-    void infoMessage(const QStringmsg);
+    void infoMessage(const QString &msg);
 
     /**
      * Is emitted if an error message with the content \a msg
      * should be shown.
      */
-    void errorMessage(const QStringmsg);
+    void errorMessage(const QString &msg);
 
     /**
      * Is emitted if an "operation completed" message with the content \a msg
      * should be shown.
      */
-    void operationCompletedMessage(const QStringmsg);
+    void operationCompletedMessage(const QString &msg);
 };
 
 #endif // KVERSIONCONTROLPLUGIN_H
-