summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/apps/textedit/textedit.cpp77
-rw-r--r--core/apps/textedit/textedit.h4
-rw-r--r--core/apps/textedit/textedit.pro4
3 files changed, 43 insertions, 42 deletions
diff --git a/core/apps/textedit/textedit.cpp b/core/apps/textedit/textedit.cpp
index b8d62db..403bd92 100644
--- a/core/apps/textedit/textedit.cpp
+++ b/core/apps/textedit/textedit.cpp
@@ -15,17 +15,17 @@
**
** Contact info@trolltech.com if any conditions of this licensing are
** not clear to you.
**
**********************************************************************/
// changes added by L. J. Potter Sun 02-17-2002 21:31:31
#include "textedit.h"
-#include "fileBrowser.h"
+//#include "fileBrowser.h"
#include "fileSaver.h"
#include "filePermissions.h"
#include "fontDialog.h"
#include <qpe/fontdatabase.h>
#include <qpe/global.h>
#include <qpe/fileselector.h>
@@ -502,55 +502,56 @@ void TextEdit::fileNew()
newFile(DocLnk());
}
void TextEdit::fileOpen()
{
Config cfg("TextEdit");
cfg.setGroup("View");
bool b=FALSE;
- if(cfg.readEntry("useOldFileDialog") == "TRUE")
- b=TRUE;
- if(!b) {
- QString str = OFileDialog::getOpenFileName( 1,"/","", "*", this );
+// if(cfg.readEntry("useOldFileDialog") == "TRUE")
+// b=TRUE;
+// if(!b) {
+ QString str = OFileDialog::getOpenFileName( 1,"/")://,"", "*", this );
if(!str.isEmpty() )
openFile( str );
- } else {
- QString str;
- browseForFiles = new fileBrowser(this,tr("Open File"),TRUE,0, "*"); //
- 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(currentFileName );
- }
- }
- viewSelection = browseForFiles->SelectionCombo->currentItem();
- }
- delete browseForFiles;
- editor->setEdited( FALSE);
- edited1=FALSE;
- edited=FALSE;
- if(caption().left(1)=="*")
- setCaption(caption().right(caption().length()-1));
- doSearchBar();
- }
+// } else {
+// QString str;
+// browseForFiles = new fileBrowser(this,tr("Open File"),TRUE,0, "*"); //
+// 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(currentFileName );
+// }
+// }
+// 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()
{
Config cfg("TextEdit");
cfg.setGroup("View");
if(cfg.readEntry("SearchBar","Closed") != "Opened")
searchBar->hide();
diff --git a/core/apps/textedit/textedit.h b/core/apps/textedit/textedit.h
index 9d27ab0..d8208b1 100644
--- a/core/apps/textedit/textedit.h
+++ b/core/apps/textedit/textedit.h
@@ -19,17 +19,17 @@
**********************************************************************/
// additions made by L.J. Potter Sun 02-17-2002 22:27:46
#ifndef TEXTEDIT_H
#define TEXTEDIT_H
#define QTEXTEDIT_OPEN_API
-#include "fileBrowser.h"
+//#include "fileBrowser.h"
#include "fileSaver.h"
#include <qpe/filemanager.h>
#include <qpe/qcopenvelope_qws.h>
#include <opie/ofileselector.h>
#include <qmainwindow.h>
@@ -106,17 +106,17 @@ private slots:
private:
void colorChanged( const QColor &c );
void clear();
void updateCaption( const QString &name=QString::null );
void setFontSize(int sz, bool round_down_not_up);
private:
fileSaver *fileSaveDlg;
- fileBrowser *browseForFiles;
+// fileBrowser *browseForFiles;
QpeEditor* editor;
QToolBar *menu, *editBar, *searchBar;
QLineEdit *searchEdit;
DocLnk *doc;
bool searchVisible;
bool bFromDocView;
int viewSelection;
QAction *zin, *zout;
diff --git a/core/apps/textedit/textedit.pro b/core/apps/textedit/textedit.pro
index 4f20da3..d01a9f4 100644
--- a/core/apps/textedit/textedit.pro
+++ b/core/apps/textedit/textedit.pro
@@ -1,14 +1,14 @@
TEMPLATE = app
CONFIG += qt warn_on release
DESTDIR = $(OPIEDIR)/bin
-HEADERS = textedit.h fileBrowser.h fontDialog.h fileSaver.h filePermissions.h
-SOURCES = main.cpp textedit.cpp fileBrowser.cpp fontDialog.cpp fileSaver.cpp filePermissions.cpp
+HEADERS = textedit.h fontDialog.h fileSaver.h filePermissions.h
+SOURCES = main.cpp textedit.cpp fontDialog.cpp fileSaver.cpp filePermissions.cpp
INCLUDEPATH += $(OPIEDIR)/include
DEPENDPATH += $(OPIEDIR)/include
LIBS += -lqpe -lopie
TARGET = textedit
TRANSLATIONS += ../i18n/de/textedit.ts