summaryrefslogtreecommitdiff
path: root/core
authorllornkcor <llornkcor>2002-04-11 23:53:23 (UTC)
committer llornkcor <llornkcor>2002-04-11 23:53:23 (UTC)
commita1615d98bdd7430e0533c0325dfdc39bf6627ab2 (patch) (side-by-side diff)
tree14989f0603a32abaa90826b2eff5fb318f99bf70 /core
parent2599e347d9444cfa6282fec9f2bfb9df4743d6d2 (diff)
downloadopie-a1615d98bdd7430e0533c0325dfdc39bf6627ab2.zip
opie-a1615d98bdd7430e0533c0325dfdc39bf6627ab2.tar.gz
opie-a1615d98bdd7430e0533c0325dfdc39bf6627ab2.tar.bz2
here ya go
Diffstat (limited to 'core') (more/less context) (ignore 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 @@
#include <qpe/qpetoolbar.h>
#include <qpe/qcopenvelope_qws.h>
//#include <qpe/finddialog.h>
+#include <opie/ofileselector.h>
#include <qstringlist.h>
#include <qaction.h>
@@ -498,36 +499,40 @@ void TextEdit::fileNew()
void TextEdit::fileOpen()
{
- browseForFiles = new fileBrowser(this,tr("Open File"),TRUE,0, "text/*"); //
- browseForFiles->setFileView( viewSelection );
- browseForFiles->showMaximized();
-// if( result != -1 )
-
- if( browseForFiles->exec() != -1 ) {
- QString selFile = browseForFiles->selectedFileName;
- QStringList fileList = browseForFiles->fileList;
- qDebug(selFile);
- QStringList::ConstIterator f;
- QString fileTemp;
- for ( f = fileList.begin(); f != fileList.end(); f++ ) {
- fileTemp = *f;
- fileTemp.right( fileTemp.length()-5);
- QString fileName = fileTemp;
- if( fileName != "Unnamed" || fileName != "Empty Text" ) {
- currentFileName = fileName;
- qDebug("please open "+currentFileName);
- openFile(fileName );
- }
- }
- viewSelection = browseForFiles->SelectionCombo->currentItem();
- }
- delete browseForFiles;
- editor->setEdited( FALSE);
- edited1=FALSE;
- edited=FALSE;
- if(caption().left(1)=="*")
- setCaption(caption().right(caption().length()-1));
- doSearchBar();
+ OFileSelector *fileSelector;
+ fileSelector = new OFileSelector( this, 1,1,"/","", "text/*");
+ fileSelector->showMaximized();
+
+// browseForFiles = new fileBrowser(this,tr("Open File"),TRUE,0, "text/*"); //
+// browseForFiles->setFileView( viewSelection );
+// browseForFiles->showMaximized();
+// // if( result != -1 )
+
+// if( browseForFiles->exec() != -1 ) {
+// QString selFile = browseForFiles->selectedFileName;
+// QStringList fileList = browseForFiles->fileList;
+// qDebug(selFile);
+// QStringList::ConstIterator f;
+// QString fileTemp;
+// for ( f = fileList.begin(); f != fileList.end(); f++ ) {
+// fileTemp = *f;
+// fileTemp.right( fileTemp.length()-5);
+// QString fileName = fileTemp;
+// if( fileName != "Unnamed" || fileName != "Empty Text" ) {
+// currentFileName = fileName;
+// qDebug("please open "+currentFileName);
+// openFile(fileName );
+// }
+// }
+// viewSelection = browseForFiles->SelectionCombo->currentItem();
+// }
+// delete browseForFiles;
+// editor->setEdited( FALSE);
+// edited1=FALSE;
+// edited=FALSE;
+// if(caption().left(1)=="*")
+// setCaption(caption().right(caption().length()-1));
+// doSearchBar();
}
void 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
INCLUDEPATH += $(OPIEDIR)/include
DEPENDPATH += $(OPIEDIR)/include
-LIBS += -lqpe
+LIBS += -lqpe -lopie
TARGET = textedit