summaryrefslogtreecommitdiff
path: root/noncore/apps/opie-gutenbrowser/LibraryDialog.cpp
authorllornkcor <llornkcor>2005-02-28 09:24:10 (UTC)
committer llornkcor <llornkcor>2005-02-28 09:24:10 (UTC)
commit61fa699140c5efbb6ba0bf2a62f7e8fbf62976be (patch) (unidiff)
tree7b3695c8a13d694487011526e3ae052b69b6d5fb /noncore/apps/opie-gutenbrowser/LibraryDialog.cpp
parent7d4beaf7922f15451da6ba65c2e21fb569887b52 (diff)
downloadopie-61fa699140c5efbb6ba0bf2a62f7e8fbf62976be.zip
opie-61fa699140c5efbb6ba0bf2a62f7e8fbf62976be.tar.gz
opie-61fa699140c5efbb6ba0bf2a62f7e8fbf62976be.tar.bz2
fix index dl from main view, user 8 bit files by default, do not show audio files
Diffstat (limited to 'noncore/apps/opie-gutenbrowser/LibraryDialog.cpp') (more/less context) (show whitespace changes)
-rw-r--r--noncore/apps/opie-gutenbrowser/LibraryDialog.cpp27
1 files changed, 17 insertions, 10 deletions
diff --git a/noncore/apps/opie-gutenbrowser/LibraryDialog.cpp b/noncore/apps/opie-gutenbrowser/LibraryDialog.cpp
index 7426e80..549c1d2 100644
--- a/noncore/apps/opie-gutenbrowser/LibraryDialog.cpp
+++ b/noncore/apps/opie-gutenbrowser/LibraryDialog.cpp
@@ -140,5 +140,8 @@ void LibraryDialog::Newlibrary()
140 } 140 }
141 141
142 if( !number.isEmpty() && (title.find( "reserved",0, FALSE) == -1) && (file.find( "]",0, TRUE) == -1) ) { 142 if( !number.isEmpty()
143 && (title.find( "reserved",0, FALSE) == -1)
144 && (file.find( "]",0, TRUE) == -1)
145 && (title.find( "Audio",0, FALSE) == -1)) {
143 146
144 // fill string list or something to be able to resort the whole library 147 // fill string list or something to be able to resort the whole library
@@ -207,6 +210,13 @@ void LibraryDialog::Library()
207 if( file.find("]",0,TRUE) != -1) 210 if( file.find("]",0,TRUE) != -1)
208 file = file.left( file.find("]",0,TRUE)); 211 file = file.left( file.find("]",0,TRUE));
209 //odebug << "file is "+file << oendl; 212
210 /// number = indexLine.mid( indexLine.find( "]", 0, TRUE ) +1, indexLine.find( " ", 0, TRUE )+1 ); 213
214 if(file.find("?", 0, false) != -1 ) {
215 QString tmpfile = file.replace(QRegExp("[?]"), "8");
216 // qDebug( "file is now " + tmpfile );
217 file = tmpfile;
218 }
219
220// number = indexLine.mid( indexLine.find( "]", 0, TRUE ) +1, indexLine.find( " ", 0, TRUE )+1 );
211 number = indexLine.mid(55,5); 221 number = indexLine.mid(55,5);
212 number = number.stripWhiteSpace(); 222 number = number.stripWhiteSpace();
@@ -230,5 +240,7 @@ void LibraryDialog::Library()
230 } 240 }
231 241
232 if( !number.isEmpty() && (title.find( "reserved",0, FALSE) == -1) /*&& (file.find( "]",0, TRUE))*/ ) { 242 if( !number.isEmpty()
243 && (title.find( "reserved",0, FALSE) == -1)
244 &&(title.find( "Audio",0, FALSE) == -1)) {
233 // fill string list or something to be able to sort by Author 245 // fill string list or something to be able to sort by Author
234 if( author.isEmpty() ) 246 if( author.isEmpty() )
@@ -597,7 +609,4 @@ bool LibraryDialog::setTitle()
597 } 609 }
598 } 610 }
599
600 if(test == 0 ) {
601
602 config.setGroup("Files"); 611 config.setGroup("Files");
603 config.writeEntry( "NumberOfFiles", i_numofFiles +1 ); 612 config.writeEntry( "NumberOfFiles", i_numofFiles +1 );
@@ -607,5 +616,5 @@ bool LibraryDialog::setTitle()
607 config.setGroup( "Titles" ); 616 config.setGroup( "Titles" );
608 config.writeEntry( File_Name, DlglistItemTitle); 617 config.writeEntry( File_Name, DlglistItemTitle);
609 } 618
610 test = 0; 619 test = 0;
611 return true; 620 return true;
@@ -751,6 +760,4 @@ void LibraryDialog::onButtonSearch()
751 resultLs = SearchResultsDialog->resultsList; 760 resultLs = SearchResultsDialog->resultsList;
752 i_berger = 1; 761 i_berger = 1;
753 } else {
754 resultLs.clear();
755 } 762 }
756 Searchlist.clear(); 763 Searchlist.clear();