-rw-r--r-- | library/global.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/library/global.cpp b/library/global.cpp index edb7b85..ab27b3f 100644 --- a/library/global.cpp +++ b/library/global.cpp | |||
@@ -660,48 +660,52 @@ void Global::findDocuments(DocLnkSet* folder, const QString &mimefilter) | |||
660 | * a) the user don't want to check mediums global | 660 | * a) the user don't want to check mediums global |
661 | * b) the user wants to check but use the global options for it | 661 | * b) the user wants to check but use the global options for it |
662 | * c) the user wants to check it but not this medium | 662 | * c) the user wants to check it but not this medium |
663 | * d) the user wants to check and this medium as well | 663 | * d) the user wants to check and this medium as well |
664 | * | 664 | * |
665 | * In all cases we need to apply a different mimefilter to | 665 | * In all cases we need to apply a different mimefilter to |
666 | * the medium. | 666 | * the medium. |
667 | * a) mimefilter.isEmpty() we need to apply the responding filter | 667 | * a) mimefilter.isEmpty() we need to apply the responding filter |
668 | * either the global or the one on the medium | 668 | * either the global or the one on the medium |
669 | * | 669 | * |
670 | * b) mimefilter is set to an application we need to find out if the | 670 | * b) mimefilter is set to an application we need to find out if the |
671 | * mimetypes are included in the mime mask of the medium | 671 | * mimetypes are included in the mime mask of the medium |
672 | */ | 672 | */ |
673 | StorageInfo storage; | 673 | StorageInfo storage; |
674 | const QList<FileSystem> &fs = storage.fileSystems(); | 674 | const QList<FileSystem> &fs = storage.fileSystems(); |
675 | QListIterator<FileSystem> it ( fs ); | 675 | QListIterator<FileSystem> it ( fs ); |
676 | for ( ; it.current(); ++it ) { | 676 | for ( ; it.current(); ++it ) { |
677 | if ( (*it)->isRemovable() ) { // let's find out if we should search on it | 677 | if ( (*it)->isRemovable() ) { // let's find out if we should search on it |
678 | // this is a candidate look at the cf and see if we should search on it | 678 | // this is a candidate look at the cf and see if we should search on it |
679 | QString path = (*it)->path(); | 679 | QString path = (*it)->path(); |
680 | if( !checkStorage((*it)->path() + "/.opiestorage.cf" ) ) | 680 | if( !checkStorage((*it)->path() + "/.opiestorage.cf" ) ) |
681 | continue; | 681 | continue; |
682 | DocLnkSet ide( path, mimefilter ); | 682 | DocLnkSet ide( path, mimefilter ); |
683 | folder->appendFrom(ide); | 683 | folder->appendFrom(ide); |
684 | } else if ( (*it)->disk() == "/dev/mtdblock6" || (*it)->disk() == "tmpfs" ) { | ||
685 | QString path = (*it)->path() + "/Documents"; | ||
686 | DocLnkSet ide( path, mimefilter ); | ||
687 | folder->appendFrom(ide); | ||
684 | } | 688 | } |
685 | } | 689 | } |
686 | } | 690 | } |
687 | 691 | ||
688 | QStringList Global::languageList() | 692 | QStringList Global::languageList() |
689 | { | 693 | { |
690 | QString lang = getenv("LANG"); | 694 | QString lang = getenv("LANG"); |
691 | QStringList langs; | 695 | QStringList langs; |
692 | langs.append(lang); | 696 | langs.append(lang); |
693 | int i = lang.find("."); | 697 | int i = lang.find("."); |
694 | if ( i > 0 ) | 698 | if ( i > 0 ) |
695 | lang = lang.left( i ); | 699 | lang = lang.left( i ); |
696 | i = lang.find( "_" ); | 700 | i = lang.find( "_" ); |
697 | if ( i > 0 ) | 701 | if ( i > 0 ) |
698 | langs.append(lang.left(i)); | 702 | langs.append(lang.left(i)); |
699 | return langs; | 703 | return langs; |
700 | } | 704 | } |
701 | 705 | ||
702 | QStringList Global::helpPath() | 706 | QStringList Global::helpPath() |
703 | { | 707 | { |
704 | QStringList path; | 708 | QStringList path; |
705 | QStringList langs = Global::languageList(); | 709 | QStringList langs = Global::languageList(); |
706 | for (QStringList::ConstIterator it = langs.fromLast(); it!=langs.end(); --it) { | 710 | for (QStringList::ConstIterator it = langs.fromLast(); it!=langs.end(); --it) { |
707 | QString lang = *it; | 711 | QString lang = *it; |