Commit fb807825 authored by Daniel Teske's avatar Daniel Teske Committed by Eike Ziller

Reduce the directories plugins are searched in

Don't search in the mac directories on linux/unix and vice versa.
Orginal patch by Ray Donnelly <mingw.android@laptop.com> on the android
branch.

Change-Id: I57a4d83a94f28bbe00609fd1b9170629da27334e
Reviewed-on: http://codereview.qt.nokia.com/3949Reviewed-by: default avatarQt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: default avatarEike Ziller <eike.ziller@nokia.com>
parent 56bf6842
......@@ -160,6 +160,7 @@ static inline QStringList getPluginPaths()
QDir rootDir = QApplication::applicationDirPath();
rootDir.cdUp();
const QString rootDirPath = rootDir.canonicalPath();
#if !defined(Q_OS_MAC)
// 1) "plugins" (Win/Linux)
QString pluginPath = rootDirPath;
pluginPath += QLatin1Char('/');
......@@ -169,11 +170,13 @@ static inline QStringList getPluginPaths()
pluginPath += QLatin1Char('/');
pluginPath += QLatin1String("plugins");
rc.push_back(pluginPath);
#else
// 2) "PlugIns" (OS X)
pluginPath = rootDirPath;
QString pluginPath = rootDirPath;
pluginPath += QLatin1Char('/');
pluginPath += QLatin1String("PlugIns");
rc.push_back(pluginPath);
#endif
return rc;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment