summaryrefslogtreecommitdiff
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/apps/opie-gutenbrowser/LibraryDialog.cpp2
-rw-r--r--noncore/apps/opie-gutenbrowser/gutenbrowser.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/noncore/apps/opie-gutenbrowser/LibraryDialog.cpp b/noncore/apps/opie-gutenbrowser/LibraryDialog.cpp
index 3b540c5..58babe9 100644
--- a/noncore/apps/opie-gutenbrowser/LibraryDialog.cpp
+++ b/noncore/apps/opie-gutenbrowser/LibraryDialog.cpp
@@ -899,65 +899,65 @@ bool LibraryDialog::onButtonDownload()
899void LibraryDialog::comboSelect(int index) 899void LibraryDialog::comboSelect(int index)
900{ 900{
901 // //odebug << "we are sorting" << oendl; 901 // //odebug << "we are sorting" << oendl;
902 ListView1->setSorting( index, true); 902 ListView1->setSorting( index, true);
903 ListView2->setSorting( index, true); 903 ListView2->setSorting( index, true);
904 ListView3->setSorting( index, true); 904 ListView3->setSorting( index, true);
905 ListView4->setSorting( index, true); 905 ListView4->setSorting( index, true);
906 ListView5->setSorting( index, true); 906 ListView5->setSorting( index, true);
907 907
908 ListView1->sort(); 908 ListView1->sort();
909 ListView2->sort(); 909 ListView2->sort();
910 ListView3->sort(); 910 ListView3->sort();
911 ListView4->sort(); 911 ListView4->sort();
912 ListView5->sort(); 912 ListView5->sort();
913 913
914 // ListView1->triggerUpdate(); 914 // ListView1->triggerUpdate();
915 // ListView2->triggerUpdate(); 915 // ListView2->triggerUpdate();
916 // ListView3->triggerUpdate(); 916 // ListView3->triggerUpdate();
917 // ListView4->triggerUpdate(); 917 // ListView4->triggerUpdate();
918 // ListView5->triggerUpdate(); 918 // ListView5->triggerUpdate();
919} 919}
920 920
921void LibraryDialog::newList() 921void LibraryDialog::newList()
922{ 922{
923 if(indexLoaded) { 923 if(indexLoaded) {
924 onButtonDownload(); 924 onButtonDownload();
925 } else { 925 } else {
926 Output *outDlg; 926 Output *outDlg;
927 buttonNewList->setDown(true); 927 buttonNewList->setDown(true);
928 //odebug << "changing dir "+QPEApplication::qpeDir()+"etc/gutenbrowser" << oendl; 928 //odebug << "changing dir "+QPEApplication::qpeDir()+"etc/gutenbrowser" << oendl;
929 QString gutenindex1 = local_library + "/GUTINDEX.ALL"; 929 QString gutenindex1 = local_library + "/GUTINDEX.ALL";
930 930
931 QString cmd="wget -O " + gutenindex1 + " http://sailor.gutenberg.org/GUTINDEX.ALL 2>&1"; 931 QString cmd="wget -O " + gutenindex1 + " http://www.gutenberg.org/dirs/GUTINDEX.ALL 2>&1";
932 932
933 int result = QMessageBox::warning( this,"Download" 933 int result = QMessageBox::warning( this,"Download"
934 ,"<p>Ok to use /'wget/' to download a new library list?</P>" 934 ,"<p>Ok to use /'wget/' to download a new library list?</P>"
935 ,"Yes","No",0,0,1); 935 ,"Yes","No",0,0,1);
936 qApp->processEvents(); 936 qApp->processEvents();
937 if(result == 0) { 937 if(result == 0) {
938 outDlg = new Output( 0, tr("Downloading Gutenberg Index...."),true); 938 outDlg = new Output( 0, tr("Downloading Gutenberg Index...."),true);
939 outDlg->showMaximized(); 939 outDlg->showMaximized();
940 outDlg->show(); 940 outDlg->show();
941 qApp->processEvents(); 941 qApp->processEvents();
942 FILE *fp; 942 FILE *fp;
943 char line[130]; 943 char line[130];
944 outDlg->OutputEdit->append( tr("Running wget") ); 944 outDlg->OutputEdit->append( tr("Running wget") );
945 outDlg->OutputEdit->setCursorPosition(outDlg->OutputEdit->numLines() + 1,0,false); 945 outDlg->OutputEdit->setCursorPosition(outDlg->OutputEdit->numLines() + 1,0,false);
946 sleep(1); 946 sleep(1);
947 fp = popen( (const char *) cmd, "r"); 947 fp = popen( (const char *) cmd, "r");
948 if ( !fp ) { 948 if ( !fp ) {
949 } else { 949 } else {
950 //odebug << "Issuing the command\n"+cmd << oendl; 950 //odebug << "Issuing the command\n"+cmd << oendl;
951 // system(cmd); 951 // system(cmd);
952 while ( fgets( line, sizeof line, fp)) { 952 while ( fgets( line, sizeof line, fp)) {
953 outDlg->OutputEdit->append(line); 953 outDlg->OutputEdit->append(line);
954 outDlg->OutputEdit->setCursorPosition(outDlg->OutputEdit->numLines() + 1,0,false); 954 outDlg->OutputEdit->setCursorPosition(outDlg->OutputEdit->numLines() + 1,0,false);
955 } 955 }
956 pclose(fp); 956 pclose(fp);
957 outDlg->OutputEdit->append("Finished downloading\n"); 957 outDlg->OutputEdit->append("Finished downloading\n");
958 outDlg->OutputEdit->setCursorPosition(outDlg->OutputEdit->numLines() + 1,0,false); 958 outDlg->OutputEdit->setCursorPosition(outDlg->OutputEdit->numLines() + 1,0,false);
959 qApp->processEvents(); 959 qApp->processEvents();
960 960
961 // if( QFile(gutenindex1).exists() ) { 961 // if( QFile(gutenindex1).exists() ) {
962 // QString gutenindex=QPEApplication::qpeDir()+"etc/gutenbrowser/GUTINDEX.ALL"; 962 // QString gutenindex=QPEApplication::qpeDir()+"etc/gutenbrowser/GUTINDEX.ALL";
963 // if( rename(gutenindex1.latin1(),gutenindex.latin1()) !=0) 963 // if( rename(gutenindex1.latin1(),gutenindex.latin1()) !=0)
diff --git a/noncore/apps/opie-gutenbrowser/gutenbrowser.cpp b/noncore/apps/opie-gutenbrowser/gutenbrowser.cpp
index e639d4d..733db17 100644
--- a/noncore/apps/opie-gutenbrowser/gutenbrowser.cpp
+++ b/noncore/apps/opie-gutenbrowser/gutenbrowser.cpp
@@ -353,65 +353,65 @@ void Gutenbrowser::DownloadIndex() {
353 case 2: // Cancel 353 case 2: // Cancel
354 break; 354 break;
355 }; 355 };
356 } 356 }
357#endif 357#endif
358} // end DownloadIndex 358} // end DownloadIndex
359 359
360 360
361void Gutenbrowser::downloadFtpList() { 361void Gutenbrowser::downloadFtpList() {
362 // QString cmd="wget http://www.promo.net/pg/list.html"); 362 // QString cmd="wget http://www.promo.net/pg/list.html");
363 //system(cmd); 363 //system(cmd);
364 qApp->processEvents(); 364 qApp->processEvents();
365 optionsDialog* optDlg; 365 optionsDialog* optDlg;
366 optDlg = new optionsDialog( this,"Options_Dlg", true); 366 optDlg = new optionsDialog( this,"Options_Dlg", true);
367 optDlg->getSite(); 367 optDlg->getSite();
368 if(optDlg) 368 if(optDlg)
369 delete optDlg; 369 delete optDlg;
370} 370}
371 371
372 372
373void Gutenbrowser::downloadLibIndex() { 373void Gutenbrowser::downloadLibIndex() {
374 // QString dwmloader = local_library + "pgwhole.zip"; 374 // QString dwmloader = local_library + "pgwhole.zip";
375 // QString cmd = "lynx -source http://www.gutenberg.net/pgwhole.zip | cat >> " + dwmloader; 375 // QString cmd = "lynx -source http://www.gutenberg.net/pgwhole.zip | cat >> " + dwmloader;
376 // system(cmd); 376 // system(cmd);
377 377
378 // QString outputFile= local_library+ "GUTINDEX.ALL"; 378 // QString outputFile= local_library+ "GUTINDEX.ALL";
379 // config.setGroup( "FTPsite" ); // ftp server config 379 // config.setGroup( "FTPsite" ); // ftp server config
380 // ftp_host=config.readEntry("SiteName", ""); 380 // ftp_host=config.readEntry("SiteName", "");
381 // ftp_base_dir= config.readEntry("base", ""); 381 // ftp_base_dir= config.readEntry("base", "");
382 // QString networkUrl= "ftp://"+ftp_host+ftp_base_dir+"/GUTINDEX.ALL"; 382 // QString networkUrl= "ftp://"+ftp_host+ftp_base_dir+"/GUTINDEX.ALL";
383 QDir dir( local_library); 383 QDir dir( local_library);
384 dir.cd("", TRUE); 384 dir.cd("", TRUE);
385 goGetit( "http://sailor.gutenberg.org/GUTINDEX.ALL", false); // until ghttp works on binaries -qt3 385 goGetit( "http://www.gutenberg.org/dirs/GUTINDEX.ALL", false); // until ghttp works on binaries -qt3
386 // goGetit( "http://www.gutenberg.net/pgwhole.zip", true); // until ghttp works on binaries -qt3 386 // goGetit( "http://www.gutenberg.net/pgwhole.zip", true); // until ghttp works on binaries -qt3
387 // NetworkDialog *NetworkDlg; 387 // NetworkDialog *NetworkDlg;
388 // NetworkDlg = new NetworkDialog( this,"Network Protocol Dialog", TRUE, 0, networkUrl, outputFile ); 388 // NetworkDlg = new NetworkDialog( this,"Network Protocol Dialog", TRUE, 0, networkUrl, outputFile );
389 // if( NetworkDlg->exec() != 0 ) 389 // if( NetworkDlg->exec() != 0 )
390 // { // use new, improved, *INSTANT* network-dialog-file-getterer 390 // { // use new, improved, *INSTANT* network-dialog-file-getterer
391 //// QMessageBox::message("Note",""); 391 //// QMessageBox::message("Note","");
392 // } 392 // }
393 // if(NetworkDlg) 393 // if(NetworkDlg)
394 // delete NetworkDlg; 394 // delete NetworkDlg;
395} 395}
396 396
397 397
398void Gutenbrowser::PrintBtn() { 398void Gutenbrowser::PrintBtn() {
399} 399}
400 400
401void Gutenbrowser::SearchBtn() { 401void Gutenbrowser::SearchBtn() {
402 if( loadCheck) { 402 if( loadCheck) {
403 odebug << "loadCheck: we have a loaded doc" << oendl; 403 odebug << "loadCheck: we have a loaded doc" << oendl;
404 Search(); 404 Search();
405 } 405 }
406 // else 406 // else
407 // QMessageBox::message("Note","Sorry, can't search. No etext is loaded"); 407 // QMessageBox::message("Note","Sorry, can't search. No etext is loaded");
408} 408}
409 409
410 410
411void Gutenbrowser::ForwardBtn() { 411void Gutenbrowser::ForwardBtn() {
412 412
413 if( !ForwardButton->autoRepeat() && !ForwardButton->isDown()) { 413 if( !ForwardButton->autoRepeat() && !ForwardButton->isDown()) {
414 414
415 QString s; 415 QString s;
416 QString insertString; 416 QString insertString;
417 int pageSize= Lview->PageSize(); 417 int pageSize= Lview->PageSize();