From a8e57d3a7e1335305fbd6ea5a65fc64b335811bb Mon Sep 17 00:00:00 2001 From: Nick Tiskov Date: Sun, 10 Nov 2013 23:24:09 +0400 Subject: [PATCH] Update misc classes --- src/filesystemwatcher.h | 4 ++-- src/geoip/geoipmanager.cpp | 2 +- src/headlessloader.h | 2 +- src/iconprovider.h | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/filesystemwatcher.h b/src/filesystemwatcher.h index dff31c42f..42c228c9a 100644 --- a/src/filesystemwatcher.h +++ b/src/filesystemwatcher.h @@ -60,8 +60,8 @@ private: private: static bool isNetworkFileSystem(QString path) { QString file = path; - if (!file.endsWith(QDir::separator())) - file += QDir::separator(); + if (!file.endsWith("/")) + file += "/"; file += "."; struct statfs buf; if (!statfs(file.toLocal8Bit().constData(), &buf)) { diff --git a/src/geoip/geoipmanager.cpp b/src/geoip/geoipmanager.cpp index 16fd491ff..9401ed091 100644 --- a/src/geoip/geoipmanager.cpp +++ b/src/geoip/geoipmanager.cpp @@ -72,7 +72,7 @@ QString GeoIPManager::geoipFolder(bool embedded) { #ifdef WITH_GEOIP_EMBEDDED if (embedded) return ":/geoip/"; - return fsutils::QDesktopServicesDataLocation()+"geoip"+QDir::separator(); + return fsutils::QDesktopServicesDataLocation()+"geoip"+"/"; #else Q_UNUSED(embedded); if (QFile::exists("/usr/local/share/GeoIP/GeoIP.dat")) diff --git a/src/headlessloader.h b/src/headlessloader.h index 1113213c9..acf1b874c 100644 --- a/src/headlessloader.h +++ b/src/headlessloader.h @@ -88,7 +88,7 @@ public slots: // the parameter type. void processParams(const QStringList& params) { foreach (QString param, params) { - param = param.trimmed(); + param = fsutils::fromNativePath(param).trimmed(); if (param.startsWith(QString::fromUtf8("http://"), Qt::CaseInsensitive) || param.startsWith(QString::fromUtf8("ftp://"), Qt::CaseInsensitive) || param.startsWith(QString::fromUtf8("https://"), Qt::CaseInsensitive)) { QBtSession::instance()->downloadFromUrl(param); }else{ diff --git a/src/iconprovider.h b/src/iconprovider.h index 3b731715c..269721a4b 100644 --- a/src/iconprovider.h +++ b/src/iconprovider.h @@ -36,7 +36,7 @@ class IconProvider { - Q_DISABLE_COPY(IconProvider); + Q_DISABLE_COPY(IconProvider) private: explicit IconProvider();