]> cloud.milkyroute.net Git - dolphin.git/commitdiff
SVN_SILENT: Minor coding style and format cleanups. No change of behavior has been...
authorPeter Penz <peter.penz19@gmail.com>
Wed, 19 May 2010 19:45:17 +0000 (19:45 +0000)
committerPeter Penz <peter.penz19@gmail.com>
Wed, 19 May 2010 19:45:17 +0000 (19:45 +0000)
svn path=/trunk/KDE/kdebase/apps/; revision=1128629

src/viewproperties.cpp
src/viewproperties.h

index 1f78fa61039ddb38044dfe71da112208e49b915a..3e08358f7308cd21673ed8a659b3cc04fca8856e 100644 (file)
@@ -1,6 +1,6 @@
 /***************************************************************************
- *   Copyright (C) 2006-2010 by Peter Penz (<peter.penz@gmx.at>)           *
- *   Copyright (C) 2006 by Aaron J. Seigo (<aseigo@kde.org>)               *
+ *   Copyright (C) 2006-2010 by Peter Penz <peter.penz@gmx.at>             *
+ *   Copyright (C) 2006 by Aaron J. Seigo <aseigo@kde.org>                 *
  *                                                                         *
  *   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  *
@@ -21,7 +21,6 @@
 #include "viewproperties.h"
 
 #include "additionalinfoaccessor.h"
-#include "settings/dolphinsettings.h"
 #include "dolphin_directoryviewpropertysettings.h"
 #include "dolphin_generalsettings.h"
 
 #include <QFile>
 #include <QFileInfo>
 
+#include "settings/dolphinsettings.h"
+
 ViewProperties::ViewProperties(const KUrl& url) :
     m_changedProps(false),
     m_autoSave(true),
     m_node(0)
 {
-    // We try and save it to a file in the directory being viewed.
+    // We try and save it to the file .directory 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.
     GeneralSettings* settings = DolphinSettings::instance().generalSettings();
     const bool useGlobalViewProps = settings->globalViewProps();
     if (useGlobalViewProps) {
-        m_filepath = destinationDir("global");
+        m_filePath = destinationDir("global");
     } else if (url.isLocalFile()) {
-        m_filepath = url.toLocalFile();
-        const QFileInfo info(m_filepath);
+        m_filePath = url.toLocalFile();
+        const QFileInfo info(m_filePath);
         if (!info.isWritable()) {
-            m_filepath = destinationDir("local") + m_filepath;
+            m_filePath = destinationDir("local") + m_filePath;
         }
     } else {
-        m_filepath = destinationDir("remote") + m_filepath;
+        m_filePath = destinationDir("remote") + m_filePath;
     }
 
-    const QString file = m_filepath + QDir::separator() + QLatin1String(".directory");
+    const QString file = m_filePath + QDir::separator() + QLatin1String(".directory");
     m_node = new ViewPropertySettings(KSharedConfig::openConfig(file));
 
     const bool useDefaultProps = !useGlobalViewProps &&
@@ -112,7 +113,6 @@ bool ViewProperties::showPreview() const
     return m_node->showPreview();
 }
 
-
 void ViewProperties::setShowHiddenFiles(bool show)
 {
     if (m_node->showHiddenFiles() != show) {
@@ -134,7 +134,6 @@ bool ViewProperties::categorizedSorting() const
     return m_node->categorizedSorting();
 }
 
-
 bool ViewProperties::showHiddenFiles() const
 {
     return m_node->showHiddenFiles();
@@ -244,7 +243,7 @@ void ViewProperties::updateTimeStamp()
 
 void ViewProperties::save()
 {
-    KStandardDirs::makeDir(m_filepath);
+    KStandardDirs::makeDir(m_filePath);
     m_node->writeConfig();
     m_changedProps = false;
 }
index c1fa191626fe719ee53e89a5bf24de098848c4cc..5179470222411dea93fa9b3fb0880e51f57f9699 100644 (file)
@@ -1,6 +1,6 @@
 /***************************************************************************
- *   Copyright (C) 2006 by Peter Penz (<peter.penz@gmx.at>)                *
- *   Copyright (C) 2006 by Aaron J. Seigo (<aseigo@kde.org>)               *
+ *   Copyright (C) 2006-2010 by Peter Penz <peter.penz@gmx.at>             *
+ *   Copyright (C) 2006 by Aaron J. Seigo <aseigo@kde.org>                 *
  *                                                                         *
  *   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  *
@@ -156,7 +156,7 @@ private:
 private:
     bool m_changedProps;
     bool m_autoSave;
-    QString m_filepath;
+    QString m_filePath;
     ViewPropertySettings* m_node;
 };