Группа :: Система/Библиотеки
Пакет: kde4libs
Главная Изменения Спек Патчи Sources Загрузить Gear Bugs and FR Repocop
Патч: kdelibs-4.1.96-alt-xdg-dirs.patch
Скачать
Скачать
--- kdelibs-4.1.96/kdecore/kernel/kstandarddirs.cpp~ 2009-01-06 20:27:48 +0300
+++ kdelibs-4.1.96/kdecore/kernel/kstandarddirs.cpp 2009-01-13 18:27:17 +0300
@@ -1560,6 +1560,8 @@ void KStandardDirs::addKDEDefaults()
if (!xdgdirs.isEmpty())
{
tokenize(xdgdirList, xdgdirs, QString(QChar(KPATH_SEPARATOR)));
+ if( !xdgdirList.contains("/etc/kde4/xdg") )
+ xdgdirList.append("/etc/kde4/xdg");
}
else
{
@@ -1569,6 +1571,7 @@ void KStandardDirs::addKDEDefaults()
xdgdirList.append(installPath("kdedir") + "etc/xdg");
#else
xdgdirList.append(KDESYSCONFDIR "/xdg");
+ xdgdirList.append("/etc/kde4/xdg");
#endif
}
@@ -1610,19 +1613,26 @@ void KStandardDirs::addKDEDefaults()
xdgdirs = readEnvPath("XDG_DATA_DIRS");
if (!xdgdirs.isEmpty()) {
- tokenize(xdgdirList, xdgdirs, QString(QChar(KPATH_SEPARATOR)));
+ QStringList xdgdirs_list;
+ tokenize(xdgdirs_list, xdgdirs, QString(QChar(KPATH_SEPARATOR)));
// Ensure the kdedirDataDirs are in there too,
// otherwise resourceDirs() will add kdedir/share/applications/kde4
// as returned by installPath(), and that's incorrect.
- Q_FOREACH(const QString& dir, kdedirDataDirs) {
+ xdgdirList = kdedirDataDirs;
+ Q_FOREACH(const QString& dir, xdgdirs_list) {
if (!xdgdirList.contains(dir))
xdgdirList.append(dir);
}
+ if( !xdgdirList.contains("/usr/share/") )
+ xdgdirList.append("/usr/share/");
+ if( !xdgdirList.contains("/var/cache/") )
+ xdgdirList.append("/var/cache/");
} else {
xdgdirList = kdedirDataDirs;
#ifndef Q_WS_WIN
xdgdirList.append("/usr/local/share/");
xdgdirList.append("/usr/share/");
+ xdgdirList.append("/var/cache/");
#endif
}
@@ -1657,6 +1667,7 @@ void KStandardDirs::addKDEDefaults()
index+=2;
}
addResourceType("exe", "lib", "kde4/libexec", true );
+ addResourceDir("emoticons", "/usr/share/emoticons", true);
addResourceDir("home", QDir::homePath(), false);
}