summaryrefslogtreecommitdiff
authorllornkcor <llornkcor>2002-03-19 00:25:30 (UTC)
committer llornkcor <llornkcor>2002-03-19 00:25:30 (UTC)
commitfbe272267851eeda20bf48aee9a01ac4dd1143c2 (patch) (side-by-side diff)
treeeb2aaea05277d12e66c712c7d109c99c1e3f8f7d
parent342ac04976065864b351c6b36087a483a8932da7 (diff)
downloadopie-fbe272267851eeda20bf48aee9a01ac4dd1143c2.zip
opie-fbe272267851eeda20bf48aee9a01ac4dd1143c2.tar.gz
opie-fbe272267851eeda20bf48aee9a01ac4dd1143c2.tar.bz2
added config entry
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/apps/textedit/textedit.cpp11
-rw-r--r--core/apps/textedit/textedit.h3
-rw-r--r--core/apps/textedit/textedit.pro4
3 files changed, 12 insertions, 6 deletions
diff --git a/core/apps/textedit/textedit.cpp b/core/apps/textedit/textedit.cpp
index d3f5fb4..f56d5d3 100644
--- a/core/apps/textedit/textedit.cpp
+++ b/core/apps/textedit/textedit.cpp
@@ -235,8 +235,9 @@ TextEdit::TextEdit( QWidget *parent, const char *name, WFlags f )
doc = 0;
edited=FALSE;
edited1=FALSE;
setToolBarsMovable( FALSE );
+ connect( qApp,SIGNAL( aboutToQuit()),SLOT( cleanUp()) );
setIcon( Resource::loadPixmap( "TextEditor" ) );
QPEToolBar *bar = new QPEToolBar( this );
@@ -406,20 +407,24 @@ TextEdit::TextEdit( QWidget *parent, const char *name, WFlags f )
}
viewSelection = cfg.readNumEntry( "FileView", 0 );
}
-TextEdit::~TextEdit()
+void TextEdit::cleanUp()
{
// save();
-
Config cfg("TextEdit");
cfg.setGroup("View");
QFont f = editor->font();
cfg.writeEntry("FontSize",f.pointSize());
cfg.writeEntry("Bold",f.bold());
cfg.writeEntry("Italic",f.italic());
cfg.writeEntry("Wrap",editor->wordWrap() == QMultiLineEdit::WidgetWidth);
- cfg.writeEntry( "FileView", viewSelection );
+ cfg.writeEntry( "FileView", viewSelection );
+
+}
+
+TextEdit::~TextEdit()
+{
}
void TextEdit::zoomIn()
{
diff --git a/core/apps/textedit/textedit.h b/core/apps/textedit/textedit.h
index aca2933..a70b581 100644
--- a/core/apps/textedit/textedit.h
+++ b/core/apps/textedit/textedit.h
@@ -70,8 +70,9 @@ private slots:
void fileOpen();
void changeStartConfig(bool);
bool save();
bool saveAs();
+ void cleanUp();
void editCut();
void editCopy();
@@ -110,9 +111,9 @@ private:
QLineEdit *searchEdit;
DocLnk *doc;
bool searchVisible;
bool bFromDocView;
- int viewSelection;
+ int viewSelection;
QAction *zin, *zout;
QString currentFileName;
};
diff --git a/core/apps/textedit/textedit.pro b/core/apps/textedit/textedit.pro
index 1301aed..37ddf15 100644
--- a/core/apps/textedit/textedit.pro
+++ b/core/apps/textedit/textedit.pro
@@ -10,6 +10,6 @@ DEPENDPATH += $(OPIEDIR)/include
LIBS += -lqpe
TARGET = textedit
-TRANSLATIONS = ../i18n/de/textedit.ts
-TRANSLATIONS = ../i18n/pt_BR/textedit.ts
+TRANSLATIONS += ../i18n/de/textedit.ts
+TRANSLATIONS += ../i18n/pt_BR/textedit.ts