summaryrefslogtreecommitdiff
authorllornkcor <llornkcor>2002-04-11 23:53:23 (UTC)
committer llornkcor <llornkcor>2002-04-11 23:53:23 (UTC)
commita1615d98bdd7430e0533c0325dfdc39bf6627ab2 (patch) (unidiff)
tree14989f0603a32abaa90826b2eff5fb318f99bf70
parent2599e347d9444cfa6282fec9f2bfb9df4743d6d2 (diff)
downloadopie-a1615d98bdd7430e0533c0325dfdc39bf6627ab2.zip
opie-a1615d98bdd7430e0533c0325dfdc39bf6627ab2.tar.gz
opie-a1615d98bdd7430e0533c0325dfdc39bf6627ab2.tar.bz2
here ya go
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--core/apps/textedit/textedit.cpp65
-rw-r--r--core/apps/textedit/textedit.pro2
2 files changed, 36 insertions, 31 deletions
diff --git a/core/apps/textedit/textedit.cpp b/core/apps/textedit/textedit.cpp
index 943fecd..a66b967 100644
--- a/core/apps/textedit/textedit.cpp
+++ b/core/apps/textedit/textedit.cpp
@@ -37,6 +37,7 @@
37#include <qpe/qpetoolbar.h> 37#include <qpe/qpetoolbar.h>
38#include <qpe/qcopenvelope_qws.h> 38#include <qpe/qcopenvelope_qws.h>
39//#include <qpe/finddialog.h> 39//#include <qpe/finddialog.h>
40#include <opie/ofileselector.h>
40 41
41#include <qstringlist.h> 42#include <qstringlist.h>
42#include <qaction.h> 43#include <qaction.h>
@@ -498,36 +499,40 @@ void TextEdit::fileNew()
498 499
499void TextEdit::fileOpen() 500void TextEdit::fileOpen()
500{ 501{
501 browseForFiles = new fileBrowser(this,tr("Open File"),TRUE,0, "text/*"); // 502 OFileSelector *fileSelector;
502 browseForFiles->setFileView( viewSelection ); 503 fileSelector = new OFileSelector( this, 1,1,"/","", "text/*");
503 browseForFiles->showMaximized(); 504 fileSelector->showMaximized();
504// if( result != -1 ) 505
505 506// browseForFiles = new fileBrowser(this,tr("Open File"),TRUE,0, "text/*"); //
506 if( browseForFiles->exec() != -1 ) { 507// browseForFiles->setFileView( viewSelection );
507 QString selFile = browseForFiles->selectedFileName; 508// browseForFiles->showMaximized();
508 QStringList fileList = browseForFiles->fileList; 509// // if( result != -1 )
509 qDebug(selFile); 510
510 QStringList::ConstIterator f; 511// if( browseForFiles->exec() != -1 ) {
511 QString fileTemp; 512// QString selFile = browseForFiles->selectedFileName;
512 for ( f = fileList.begin(); f != fileList.end(); f++ ) { 513// QStringList fileList = browseForFiles->fileList;
513 fileTemp = *f; 514// qDebug(selFile);
514 fileTemp.right( fileTemp.length()-5); 515// QStringList::ConstIterator f;
515 QString fileName = fileTemp; 516// QString fileTemp;
516 if( fileName != "Unnamed" || fileName != "Empty Text" ) { 517// for ( f = fileList.begin(); f != fileList.end(); f++ ) {
517 currentFileName = fileName; 518// fileTemp = *f;
518 qDebug("please open "+currentFileName); 519// fileTemp.right( fileTemp.length()-5);
519 openFile(fileName ); 520// QString fileName = fileTemp;
520 } 521// if( fileName != "Unnamed" || fileName != "Empty Text" ) {
521 } 522// currentFileName = fileName;
522 viewSelection = browseForFiles->SelectionCombo->currentItem(); 523// qDebug("please open "+currentFileName);
523 } 524// openFile(fileName );
524 delete browseForFiles; 525// }
525 editor->setEdited( FALSE); 526// }
526 edited1=FALSE; 527// viewSelection = browseForFiles->SelectionCombo->currentItem();
527 edited=FALSE; 528// }
528 if(caption().left(1)=="*") 529// delete browseForFiles;
529 setCaption(caption().right(caption().length()-1)); 530// editor->setEdited( FALSE);
530 doSearchBar(); 531// edited1=FALSE;
532// edited=FALSE;
533// if(caption().left(1)=="*")
534// setCaption(caption().right(caption().length()-1));
535// doSearchBar();
531} 536}
532 537
533void TextEdit::doSearchBar() 538void TextEdit::doSearchBar()
diff --git a/core/apps/textedit/textedit.pro b/core/apps/textedit/textedit.pro
index fce76bd..aae7f89 100644
--- a/core/apps/textedit/textedit.pro
+++ b/core/apps/textedit/textedit.pro
@@ -7,7 +7,7 @@ SOURCES = main.cpp textedit.cpp fileBrowser.cpp fontDialog.cpp fileSaver.cpp fil
7 7
8INCLUDEPATH += $(OPIEDIR)/include 8INCLUDEPATH += $(OPIEDIR)/include
9DEPENDPATH += $(OPIEDIR)/include 9DEPENDPATH += $(OPIEDIR)/include
10LIBS += -lqpe 10LIBS += -lqpe -lopie
11 11
12TARGET = textedit 12TARGET = textedit
13 13