-rw-r--r-- | core/apps/textedit/textedit.cpp | 60 |
1 files changed, 12 insertions, 48 deletions
diff --git a/core/apps/textedit/textedit.cpp b/core/apps/textedit/textedit.cpp index ccc43fa..ea27e1b 100644 --- a/core/apps/textedit/textedit.cpp +++ b/core/apps/textedit/textedit.cpp | |||
@@ -22,8 +22,9 @@ | |||
22 | #include "textedit.h" | 22 | #include "textedit.h" |
23 | //#include "fileBrowser.h" | ||
24 | #include "fileSaver.h" | 23 | #include "fileSaver.h" |
25 | #include "filePermissions.h" | 24 | #include "filePermissions.h" |
26 | |||
27 | #include "fontDialog.h" | 25 | #include "fontDialog.h" |
28 | 26 | ||
27 | #include <opie/ofileselector.h> | ||
28 | #include <opie/ofiledialog.h> | ||
29 | |||
29 | #include <qpe/fontdatabase.h> | 30 | #include <qpe/fontdatabase.h> |
@@ -38,6 +39,2 @@ | |||
38 | #include <qpe/qcopenvelope_qws.h> | 39 | #include <qpe/qcopenvelope_qws.h> |
39 | //#include <qpe/finddialog.h> | ||
40 | |||
41 | #include <opie/ofileselector.h> | ||
42 | #include <opie/ofiledialog.h> | ||
43 | 40 | ||
@@ -509,46 +506,13 @@ void TextEdit::fileOpen() | |||
509 | bool b=FALSE; | 506 | bool b=FALSE; |
510 | // if(cfg.readEntry("useOldFileDialog") == "TRUE") | 507 | |
511 | // b=TRUE; | 508 | QMap<QString, QStringList> map; |
512 | // if(!b) { | 509 | map.insert(tr("All"), QStringList() ); |
513 | QMap<QString, QStringList> map; | 510 | QStringList text; |
514 | map.insert(tr("All"), QStringList() ); | 511 | text << "text/*"; |
515 | QStringList text; | 512 | map.insert(tr("Text"), text ); |
516 | text << "text/*"; | 513 | text << "*"; |
517 | map.insert(tr("Text"), text ); | 514 | map.insert(tr("All"), text ); |
518 | QString str = OFileDialog::getOpenFileName( 2,"/", QString::null, map);//,"", "*", this ); | 515 | QString str = OFileDialog::getOpenFileName( 2,"/", QString::null, map); |
519 | if(!str.isEmpty() ) | 516 | if(!str.isEmpty() ) |
520 | openFile( str ); | 517 | openFile( str ); |
521 | // } else { | ||
522 | // QString str; | ||
523 | // browseForFiles = new fileBrowser(this,tr("Open File"),TRUE,0, "*"); // | ||
524 | // browseForFiles->setFileView( viewSelection ); | ||
525 | // browseForFiles->showMaximized(); | ||
526 | // // if( result != -1 ) | ||
527 | |||
528 | // if( browseForFiles->exec() != -1 ) { | ||
529 | // QString selFile = browseForFiles->selectedFileName; | ||
530 | // QStringList fileList = browseForFiles->fileList; | ||
531 | // qDebug(selFile); | ||
532 | // QStringList::ConstIterator f; | ||
533 | // QString fileTemp; | ||
534 | // for ( f = fileList.begin(); f != fileList.end(); f++ ) { | ||
535 | // fileTemp = *f; | ||
536 | // fileTemp.right( fileTemp.length()-5); | ||
537 | // QString fileName = fileTemp; | ||
538 | // if( fileName != "Unnamed" || fileName != "Empty Text" ) { | ||
539 | // currentFileName = fileName; | ||
540 | // qDebug("please open "+currentFileName); | ||
541 | // openFile(currentFileName ); | ||
542 | // } | ||
543 | // } | ||
544 | // viewSelection = browseForFiles->SelectionCombo->currentItem(); | ||
545 | // } | ||
546 | // delete browseForFiles; | ||
547 | // editor->setEdited( FALSE); | ||
548 | // edited1=FALSE; | ||
549 | // edited=FALSE; | ||
550 | // if(caption().left(1)=="*") | ||
551 | // setCaption(caption().right(caption().length()-1)); | ||
552 | // doSearchBar(); | ||
553 | // } | ||
554 | 518 | ||