author | ulf69 <ulf69> | 2004-06-29 05:35:06 (UTC) |
---|---|---|
committer | ulf69 <ulf69> | 2004-06-29 05:35:06 (UTC) |
commit | b863f47dbb927a54f492b70ac59f3f99202dd7ca (patch) (unidiff) | |
tree | c5fffc44350972f0e7c963ea1ac98f2d5ce2dcfa | |
parent | ed68714fca68286417778f0f5378b9f65d4acaa3 (diff) | |
download | kdepimpi-b863f47dbb927a54f492b70ac59f3f99202dd7ca.zip kdepimpi-b863f47dbb927a54f492b70ac59f3f99202dd7ca.tar.gz kdepimpi-b863f47dbb927a54f492b70ac59f3f99202dd7ca.tar.bz2 |
added Qtopia as directory to search for libraries (Qtopia/libs)
-rw-r--r-- | microkde/kdecore/kstandarddirs.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/microkde/kdecore/kstandarddirs.cpp b/microkde/kdecore/kstandarddirs.cpp index 5abe05c..1a1e027 100644 --- a/microkde/kdecore/kstandarddirs.cpp +++ b/microkde/kdecore/kstandarddirs.cpp | |||
@@ -40,12 +40,13 @@ | |||
40 | #include <qasciidict.h> | 40 | #include <qasciidict.h> |
41 | #include <qdict.h> | 41 | #include <qdict.h> |
42 | #include <qdir.h> | 42 | #include <qdir.h> |
43 | #include <qfileinfo.h> | 43 | #include <qfileinfo.h> |
44 | #include <qstring.h> | 44 | #include <qstring.h> |
45 | #include <qstringlist.h> | 45 | #include <qstringlist.h> |
46 | #include <qpe/qpeapplication.h> | ||
46 | 47 | ||
47 | #include "kstandarddirs.h" | 48 | #include "kstandarddirs.h" |
48 | #include "kconfig.h" | 49 | #include "kconfig.h" |
49 | #include "kdebug.h" | 50 | #include "kdebug.h" |
50 | //US #include "kinstance.h" | 51 | //US #include "kinstance.h" |
51 | #include "kshell.h" | 52 | #include "kshell.h" |
@@ -347,16 +348,17 @@ QString KStandardDirs::findResourceDir( const char *type, | |||
347 | 348 | ||
348 | if (d && d->restrictionsActive && (strcmp(type, "data")==0)) | 349 | if (d && d->restrictionsActive && (strcmp(type, "data")==0)) |
349 | applyDataRestrictions(filename); | 350 | applyDataRestrictions(filename); |
350 | QStringList candidates = resourceDirs(type); | 351 | QStringList candidates = resourceDirs(type); |
351 | QString fullPath; | 352 | QString fullPath; |
352 | 353 | ||
353 | for (QStringList::ConstIterator it = candidates.begin(); | 354 | for (QStringList::ConstIterator it = candidates.begin(); it != candidates.end(); it++) |
354 | it != candidates.end(); it++) | 355 | { |
355 | if (exists(*it + filename)) | 356 | if (exists(*it + filename)) |
356 | return *it; | 357 | return *it; |
358 | } | ||
357 | 359 | ||
358 | #ifndef NDEBUG | 360 | #ifndef NDEBUG |
359 | if(false && type != "locale") | 361 | if(false && type != "locale") |
360 | kdDebug() << "KStdDirs::findResDir(): can't find \"" << filename << "\" in type \"" << type << "\"." << endl; | 362 | kdDebug() << "KStdDirs::findResDir(): can't find \"" << filename << "\" in type \"" << type << "\"." << endl; |
361 | #endif | 363 | #endif |
362 | 364 | ||
@@ -394,12 +396,13 @@ static void lookupDirectory(const QString& path, const QString &relPart, | |||
394 | QString pattern = regexp.pattern(); | 396 | QString pattern = regexp.pattern(); |
395 | if (recursive || pattern.contains('?') || pattern.contains('*')) | 397 | if (recursive || pattern.contains('?') || pattern.contains('*')) |
396 | { | 398 | { |
397 | // We look for a set of files. | 399 | // We look for a set of files. |
398 | //US DIR *dp = opendir( QFile::encodeName(path)); | 400 | //US DIR *dp = opendir( QFile::encodeName(path)); |
399 | QDir dp(QFile::encodeName(path)); | 401 | QDir dp(QFile::encodeName(path)); |
402 | |||
400 | if (!dp.exists()) | 403 | if (!dp.exists()) |
401 | return; | 404 | return; |
402 | static int iii = 0; | 405 | static int iii = 0; |
403 | ++iii; | 406 | ++iii; |
404 | if ( iii == 5 ) | 407 | if ( iii == 5 ) |
405 | abort(); | 408 | abort(); |
@@ -1218,12 +1221,14 @@ void KStandardDirs::addKDEDefaults() | |||
1218 | { | 1221 | { |
1219 | kdedir = KShell::tildeExpand(kdedir); | 1222 | kdedir = KShell::tildeExpand(kdedir); |
1220 | kdedirList.append(kdedir); | 1223 | kdedirList.append(kdedir); |
1221 | } | 1224 | } |
1222 | } | 1225 | } |
1223 | //US kdedirList.append(KDEDIR); | 1226 | //US kdedirList.append(KDEDIR); |
1227 | //US for embedded, add qtopia dir as kdedir | ||
1228 | kdedirList.append(QPEApplication::qpeDir()); | ||
1224 | 1229 | ||
1225 | #ifdef __KDE_EXECPREFIX | 1230 | #ifdef __KDE_EXECPREFIX |
1226 | QString execPrefix(__KDE_EXECPREFIX); | 1231 | QString execPrefix(__KDE_EXECPREFIX); |
1227 | if (execPrefix!="NONE") | 1232 | if (execPrefix!="NONE") |
1228 | kdedirList.append(execPrefix); | 1233 | kdedirList.append(execPrefix); |
1229 | #endif | 1234 | #endif |