author | llornkcor <llornkcor> | 2005-08-25 08:23:59 (UTC) |
---|---|---|
committer | llornkcor <llornkcor> | 2005-08-25 08:23:59 (UTC) |
commit | 938d1f0a0c16a8acbd7866191d099a4054c4c3e2 (patch) (unidiff) | |
tree | 3d7de3be92a8a15ad16b4dc9b5fd6fd207e1fa7e | |
parent | 65edeafe2dc8689dce7c2ce94e954933b393dcf0 (diff) | |
download | opie-938d1f0a0c16a8acbd7866191d099a4054c4c3e2.zip opie-938d1f0a0c16a8acbd7866191d099a4054c4c3e2.tar.gz opie-938d1f0a0c16a8acbd7866191d099a4054c4c3e2.tar.bz2 |
fix search results
-rw-r--r-- | noncore/apps/opie-gutenbrowser/LibraryDialog.cpp | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/noncore/apps/opie-gutenbrowser/LibraryDialog.cpp b/noncore/apps/opie-gutenbrowser/LibraryDialog.cpp index 9858188..6c246e97 100644 --- a/noncore/apps/opie-gutenbrowser/LibraryDialog.cpp +++ b/noncore/apps/opie-gutenbrowser/LibraryDialog.cpp | |||
@@ -770,24 +770,25 @@ void LibraryDialog::parseSearchResults( QString resultStr) | |||
770 | my.setNum( stringLeng, 10); | 770 | my.setNum( stringLeng, 10); |
771 | 771 | ||
772 | if( resultStr.length() > 2 && resultStr.length() < 130) { | 772 | if( resultStr.length() > 2 && resultStr.length() < 130) { |
773 | QStringList token = QStringList::split(" : ", resultStr); | ||
773 | 774 | ||
774 | int titleInt = resultStr.find( " : ", 0, true); | 775 | DlglistItemTitle = token[0]; |
775 | DlglistItemTitle = resultStr.left( titleInt); | 776 | DlglistItemTitle = DlglistItemTitle.stripWhiteSpace(); |
776 | 777 | ||
777 | int yearInt = resultStr.find( " : ", titleInt+3, true); | 778 | DlglistItemYear = token[1]; |
779 | DlglistItemYear = DlglistItemYear.stripWhiteSpace(); | ||
778 | 780 | ||
779 | DlglistItemYear = resultStr.mid( titleInt+3, (yearInt - titleInt)-3); | 781 | DlglistItemFile = token[2]; |
780 | 782 | ||
781 | DlglistItemFile = resultStr.right( resultStr.length() - (yearInt + 3)); | 783 | DlglistItemFile = DlglistItemFile.stripWhiteSpace(); |
782 | DlglistItemFile = DlglistItemFile.left( DlglistItemFile.length() - 2); | 784 | |
785 | // qWarning(DlglistItemYear); | ||
783 | 786 | ||
784 | cleanStrings(); | ||
785 | 787 | ||
786 | if(DlglistItemFile.left(1) == "/") | 788 | if(DlglistItemFile.left(1) == "/") |
787 | DlglistItemFile = DlglistItemFile.right( DlglistItemFile.length() - 1); | 789 | DlglistItemFile = DlglistItemFile.right( DlglistItemFile.length() - 1); |
788 | 790 | ||
789 | 791 | if(DlglistItemFile.toInt() > 10000 || DlglistItemYear == "1980" ) { | |
790 | if(DlglistItemFile.toInt() > 10000 || yearInt == 1980 ) { | ||
791 | // new directory sturcture | 792 | // new directory sturcture |
792 | download_newEtext(); //) | 793 | download_newEtext(); //) |
793 | } else { | 794 | } else { |