]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/viewproperties.h
Create the new architecture for KCategorizedView. Now DolphinModel is created, inheri...
[dolphin.git] / src / viewproperties.h
index b4d9500bc66e57c1e905c59b2bcc4c564de745b7..64a2fad256ba829be8c100e84ea22c1d5930000c 100644 (file)
 
 #include <dolphinview.h>
 #include <kurl.h>
-#include <qdatetime.h>
-
-#include "directoryviewpropertysettings.h"
-
-class QFile;
+#include <libdolphin_export.h>
 
+class ViewPropertySettings;
 /**
  * @brief Maintains the view properties like 'view mode' or
  *        'show hidden files' for a directory.
@@ -50,7 +47,7 @@ class QFile;
  * (see GeneralSettings::globalViewMode()), the values from the global .directory file
  * are used for initialization.
  */
-class ViewProperties
+class LIBDOLPHINPRIVATE_EXPORT ViewProperties
 {
 public:
     explicit ViewProperties(const KUrl& url);
@@ -65,12 +62,18 @@ public:
     void setShowHiddenFiles(bool show);
     bool showHiddenFiles() const;
 
+    void setCategorizedSorting(bool categorized);
+    bool categorizedSorting() const;
+
     void setSorting(DolphinView::Sorting sorting);
     DolphinView::Sorting sorting() const;
 
     void setSortOrder(Qt::SortOrder sortOrder);
     Qt::SortOrder sortOrder() const;
 
+    void setAdditionalInfo(KFileItemDelegate::AdditionalInformation info);
+    KFileItemDelegate::AdditionalInformation additionalInfo() const;
+
     /**
      * Sets the directory properties view mode, show preview,
      * show hidden files, sorting and sort order like
@@ -97,6 +100,15 @@ public:
      */
     void save();
 
+    /**
+     * Returns the URL of the directory, where the mirrored view properties
+     * are stored into. Mirrored view properties are used if:
+     * - there is no write access for storing the view properties into
+     *   the original directory
+     * - for non local directories
+     */
+    static KUrl mirroredDirectory();
+
 private:
     /**
      * Returns the destination directory path where the view
@@ -105,8 +117,7 @@ private:
      */
     QString destinationDir(const QString& subDir) const;
 
-    ViewProperties(const ViewProperties& props);
-    ViewProperties& operator= (const ViewProperties& props);
+    Q_DISABLE_COPY(ViewProperties)
 
 private:
     bool m_changedProps;