Diffstat (limited to 'noncore/apps/tinykate/tinykate.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/apps/tinykate/tinykate.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/noncore/apps/tinykate/tinykate.cpp b/noncore/apps/tinykate/tinykate.cpp index f470645..bbf80ce 100644 --- a/noncore/apps/tinykate/tinykate.cpp +++ b/noncore/apps/tinykate/tinykate.cpp | |||
@@ -14,25 +14,25 @@ | |||
14 | * ONLY VERSION 2 OF THE LICENSE IS APPLICABLE * | 14 | * ONLY VERSION 2 OF THE LICENSE IS APPLICABLE * |
15 | * * | 15 | * * |
16 | ***************************************************************************/ | 16 | ***************************************************************************/ |
17 | #include <qwidget.h> | 17 | #include <qwidget.h> |
18 | #include <qaction.h> | 18 | #include <qaction.h> |
19 | #include <qlayout.h> | 19 | #include <qlayout.h> |
20 | #include <qtoolbutton.h> | 20 | #include <qtoolbutton.h> |
21 | #include <qmenubar.h> | 21 | #include <qmenubar.h> |
22 | #include <qpe/resource.h> | 22 | #include <qpe/resource.h> |
23 | #include <qpe/global.h> | 23 | #include <qpe/global.h> |
24 | #include <qpe/qpeapplication.h> | 24 | #include <qpe/qpeapplication.h> |
25 | 25 | ||
26 | #include <opie/ofiledialog.h> | 26 | #include <opie2/ofiledialog.h> |
27 | 27 | ||
28 | #include "tinykate.h" | 28 | #include "tinykate.h" |
29 | 29 | ||
30 | #include <katedocument.h> | 30 | #include <katedocument.h> |
31 | #include <katehighlight.h> | 31 | #include <katehighlight.h> |
32 | #include <kateview.h> | 32 | #include <kateview.h> |
33 | #include <kglobal.h> | 33 | #include <kglobal.h> |
34 | 34 | ||
35 | TinyKate::TinyKate( QWidget *parent, const char *name, WFlags f) : | 35 | TinyKate::TinyKate( QWidget *parent, const char *name, WFlags f) : |
36 | QMainWindow( parent, name, f ) | 36 | QMainWindow( parent, name, f ) |
37 | { | 37 | { |
38 | shutDown=false; | 38 | shutDown=false; |
@@ -162,25 +162,25 @@ TinyKate::~TinyKate( ) | |||
162 | while (currentView!=0) { | 162 | while (currentView!=0) { |
163 | slotClose(); | 163 | slotClose(); |
164 | } | 164 | } |
165 | 165 | ||
166 | if( KGlobal::config() != 0 ) { | 166 | if( KGlobal::config() != 0 ) { |
167 | qWarning("deleting KateConfig object..\n"); | 167 | qWarning("deleting KateConfig object..\n"); |
168 | delete KGlobal::config(); | 168 | delete KGlobal::config(); |
169 | } | 169 | } |
170 | } | 170 | } |
171 | 171 | ||
172 | void TinyKate::slotOpen( ) | 172 | void TinyKate::slotOpen( ) |
173 | { | 173 | { |
174 | QString filename = OFileDialog::getOpenFileName( OFileSelector::EXTENDED_ALL, | 174 | QString filename = Opie::OFileDialog::getOpenFileName( OFileSelector::EXTENDED_ALL, |
175 | QString::null); | 175 | QString::null); |
176 | if (!filename.isEmpty()) { | 176 | if (!filename.isEmpty()) { |
177 | open(filename); | 177 | open(filename); |
178 | } | 178 | } |
179 | } | 179 | } |
180 | 180 | ||
181 | void TinyKate::open(const QString & filename) | 181 | void TinyKate::open(const QString & filename) |
182 | { | 182 | { |
183 | KateDocument *kd= new KateDocument(false, false, this,0,this); | 183 | KateDocument *kd= new KateDocument(false, false, this,0,this); |
184 | KTextEditor::View *kv; | 184 | KTextEditor::View *kv; |
185 | QFileInfo fi(filename); | 185 | QFileInfo fi(filename); |
186 | QString filenamed = fi.fileName(); | 186 | QString filenamed = fi.fileName(); |
@@ -257,25 +257,25 @@ void TinyKate::slotSave() { | |||
257 | if( kd->docName().isEmpty()) | 257 | if( kd->docName().isEmpty()) |
258 | slotSaveAs(); | 258 | slotSaveAs(); |
259 | else | 259 | else |
260 | kd->saveFile(); | 260 | kd->saveFile(); |
261 | // kv->save(); | 261 | // kv->save(); |
262 | // kd->saveFile(); | 262 | // kd->saveFile(); |
263 | } | 263 | } |
264 | 264 | ||
265 | void TinyKate::slotSaveAs() { | 265 | void TinyKate::slotSaveAs() { |
266 | if (currentView==0) return; | 266 | if (currentView==0) return; |
267 | KateDocument *kd = (KateDocument*) currentView->document(); | 267 | KateDocument *kd = (KateDocument*) currentView->document(); |
268 | 268 | ||
269 | QString filename=OFileDialog::getSaveFileName(OFileSelector::EXTENDED_ALL, | 269 | QString filename= Opie::OFileDialog::getSaveFileName(OFileSelector::EXTENDED_ALL, |
270 | QString::null); | 270 | QString::null); |
271 | if (!filename.isEmpty()) { | 271 | if (!filename.isEmpty()) { |
272 | qDebug("saving file "+filename); | 272 | qDebug("saving file "+filename); |
273 | QFileInfo fi(filename); | 273 | QFileInfo fi(filename); |
274 | QString filenamed = fi.fileName(); | 274 | QString filenamed = fi.fileName(); |
275 | kd->setDocFile( filename); | 275 | kd->setDocFile( filename); |
276 | kd->setDocName( filenamed); | 276 | kd->setDocName( filenamed); |
277 | kd->saveFile(); | 277 | kd->saveFile(); |
278 | // KTextEditor::View *dv = currentView; | 278 | // KTextEditor::View *dv = currentView; |
279 | // tabwidget->changeTab( dv, filenamed); | 279 | // tabwidget->changeTab( dv, filenamed); |
280 | // need to change tab label here | 280 | // need to change tab label here |
281 | } | 281 | } |