]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/viewproperties.cpp
fix signal names
[dolphin.git] / src / viewproperties.cpp
index d099b3b22d48e244ba8eed9cd030f599e793677f..60e91cabf354c2bb75ea982addb2f6d34aae0cce 100644 (file)
@@ -50,9 +50,9 @@ ViewProperties::ViewProperties(const KUrl& url) :
         return;
     }
 
-    // we try and save it to a file in the directory being viewed
-    // if the directory is not writable by the user or the directory is not local
-    // we store the properties information in a local file
+    // We try and save it to a file in the directory being viewed.
+    // If the directory is not writable by the user or the directory is not local,
+    // we store the properties information in a local file.
     QString rootDir("/"); // TODO: should this be set to the root of the bookmark, if any?
     if (cleanUrl.isLocalFile()) {
         QFileInfo info(m_filepath);
@@ -97,7 +97,21 @@ DolphinView::Mode ViewProperties::viewMode() const
     return static_cast<DolphinView::Mode>(m_node->viewMode());
 }
 
-void ViewProperties::setShowHiddenFilesEnabled(bool show)
+void ViewProperties::setShowPreview(bool show)
+{
+    if (m_node->showPreview() != show) {
+        m_node->setShowPreview(show);
+        updateTimeStamp();
+    }
+}
+
+bool ViewProperties::showPreview() const
+{
+    return m_node->showPreview();
+}
+
+
+void ViewProperties::setShowHiddenFiles(bool show)
 {
     if (m_node->showHiddenFiles() != show) {
         m_node->setShowHiddenFiles(show);
@@ -105,7 +119,7 @@ void ViewProperties::setShowHiddenFilesEnabled(bool show)
     }
 }
 
-bool ViewProperties::isShowHiddenFilesEnabled() const
+bool ViewProperties::showHiddenFiles() const
 {
     return m_node->showHiddenFiles();
 }