diff options
Diffstat (limited to 'kwordquiz/src/kwordquizdoc.cpp')
-rw-r--r-- | kwordquiz/src/kwordquizdoc.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/kwordquiz/src/kwordquizdoc.cpp b/kwordquiz/src/kwordquizdoc.cpp index f5309636..9325c5bb 100644 --- a/kwordquiz/src/kwordquizdoc.cpp +++ b/kwordquiz/src/kwordquizdoc.cpp @@ -15,7 +15,7 @@ * * ***************************************************************************/ -// include files for Qt +// include files for TQt // include files for KDE #include <klocale.h> @@ -33,15 +33,15 @@ #include "wqlwriter.h" #include "prefs.h" -//QList<KWordQuizView> *KWordQuizDoc::pViewList = 0L; +//TQList<KWordQuizView> *KWordQuizDoc::pViewList = 0L; //KWordQuizView *KWordQuizDoc::m_view; -KWordQuizDoc::KWordQuizDoc(TQWidget *parent, const char *name) : TQObject(parent, name) +KWordQuizDoc::KWordQuizDoc(TQWidget *tqparent, const char *name) : TQObject(tqparent, name) { connect(KDirWatch::self(), TQT_SIGNAL(dirty(const TQString& )), this, TQT_SLOT(slotModifiedOnDisk(const TQString& ))); /* if(!pViewList) { - pViewList = new QList<KWordQuizView>(); + pViewList = new TQList<KWordQuizView>(); } pViewList->setAutoDelete(true);*/ @@ -73,14 +73,14 @@ const KURL& KWordQuizDoc::URL() const void KWordQuizDoc::slotUpdateAllViews(KWordQuizView *sender) { - //m_view->repaint(); + //m_view->tqrepaint(); /*KWordQuizView *w; if(pViewList) { for(w=pViewList->first(); w!=0; w=pViewList->next()) { if(w!=sender) - w->repaint(); + w->tqrepaint(); } }*/ @@ -105,7 +105,7 @@ bool KWordQuizDoc::saveModified() if(modified) { - KWordQuizApp *win=(KWordQuizApp *) parent(); + KWordQuizApp *win=(KWordQuizApp *) tqparent(); int want_save = KMessageBox::warningYesNoCancel(win, i18n("The current file has been modified.\n" "Do you want to save it?"), @@ -162,7 +162,7 @@ bool KWordQuizDoc::openDocument(const KURL& url, bool append, int index) TQFile file(tmpfile); if (!file.open(IO_ReadOnly)) { - KMessageBox::error(0, i18n("<qt>Cannot open file<br><b>%1</b></qt>").arg(url.path())); + KMessageBox::error(0, i18n("<qt>Cannot open file<br><b>%1</b></qt>").tqarg(url.path())); return false; } @@ -317,7 +317,7 @@ bool KWordQuizDoc::openDocument(const KURL& url, bool append, int index) } g->setUpdatesEnabled(true); - g->repaintContents(); + g->tqrepaintContents(); } modified=false; if (append) @@ -333,7 +333,7 @@ bool KWordQuizDoc::saveDocument(const KURL& url, const char *format /*=0*/) if (!file.open(IO_WriteOnly)) { KMessageBox::error(0, i18n("<qt>Cannot write to file<br><b>%1</b></qt>") - .arg(url.path())); + .tqarg(url.path())); //if (filename == fname) // filename = ""; return false; @@ -347,7 +347,7 @@ bool KWordQuizDoc::saveDocument(const KURL& url, const char *format /*=0*/) { file.close(); KVTMLWriter writer(&file); - writer.addHeader(TQString("kwordquiz %1").arg(KWQ_VERSION), 2, g->numRows(), url.fileName()); + writer.addHeader(TQString("kwordquiz %1").tqarg(KWTQ_VERSION), 2, g->numRows(), url.fileName()); writer.addFirstItem(g->horizontalHeader()->label(0), g->columnWidth(0), g->text(w, 0), g->horizontalHeader()->label(1), g->columnWidth(1), g->text(w, 1)); w++; int r = g->numRows(); @@ -479,8 +479,8 @@ void KWordQuizDoc::slotModifiedOnDisk( const TQString & path) /*@todo this code doesn't work very well. Have to look in more detail on how Kate does it. if (doc_url.path() == path) { - TQString str = i18n("The file %1 was changed (modified) on disc by another program!\n\n").arg(doc_url.fileName()); - int i = KMessageBox::warningYesNoCancel(0, str + i18n("Do you want to reload the modified file? Data loss may occur."),TQString::null,i18n("Reload"),i18n("Do Not Reload")); + TQString str = i18n("The file %1 was changed (modified) on disc by another program!\n\n").tqarg(doc_url.fileName()); + int i = KMessageBox::warningYesNoCancel(0, str + i18n("Do you want to reload the modified file? Data loss may occur."),TQString(),i18n("Reload"),i18n("Do Not Reload")); if ( i == KMessageBox::Yes) openDocument(doc_url); } |