diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-04-13 00:46:47 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-04-13 00:46:47 +0000 |
commit | 67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7 (patch) | |
tree | 5f52a9eada2e9f3654fc327d7c14dfef570a6ecb /ktnef/gui/ktnefmain.cpp | |
parent | 2ee4bf4fd5eff93b2fbef0ff8e8063edffc5da5c (diff) | |
download | tdepim-67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7.tar.gz tdepim-67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7.zip |
Initial conversion of kdepim to TQt
This will probably require some tweaking before it will build under Qt4,
however Qt3 builds are OK. Any alterations this commit makes to kdepim
behaviour under Qt3 are unintentional and should be fixed.
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1227832 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'ktnef/gui/ktnefmain.cpp')
-rw-r--r-- | ktnef/gui/ktnefmain.cpp | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/ktnef/gui/ktnefmain.cpp b/ktnef/gui/ktnefmain.cpp index ea44edbe1..fd9438e6c 100644 --- a/ktnef/gui/ktnefmain.cpp +++ b/ktnef/gui/ktnefmain.cpp @@ -57,8 +57,8 @@ #define NOT_IMPLEMENTED TQMessageBox::information(this, "ktnef", "Not implemented yet", TQMessageBox::Ok|TQMessageBox::Default, 0) -KTNEFMain::KTNEFMain(TQWidget *parent, const char *name) - : KMainWindow(parent, name) +KTNEFMain::KTNEFMain(TQWidget *tqparent, const char *name) + : KMainWindow(tqparent, name) { setupActions(); setupStatusbar(); @@ -154,7 +154,7 @@ void KTNEFMain::loadFile(const TQString& filename) else { TQPtrList<KTNEFAttach> list = parser_->message()->attachmentList(); - QString msg; + TQString msg; msg = i18n( "%n attachment found", "%n attachments found", list.count() ); statusBar()->changeItem(msg, 0); view_->setAttachments(&list); @@ -165,7 +165,7 @@ void KTNEFMain::loadFile(const TQString& filename) void KTNEFMain::openFile() { - QString filename = KFileDialog::getOpenFileName(0,0,this,0); + TQString filename = KFileDialog::getOpenFileName(0,0,this,0); if (!filename.isEmpty()) loadFile(filename); } @@ -173,7 +173,7 @@ void KTNEFMain::viewFile() { KTNEFAttach *attach = view_->getSelection()->first(); KURL url("file:"+extractTemp(attach)); - QString mimename(attach->mimeTag()); + TQString mimename(attach->mimeTag()); if (mimename.isEmpty() || mimename == "application/octet-stream") { @@ -189,7 +189,7 @@ void KTNEFMain::viewFile() TQString KTNEFMain::extractTemp(KTNEFAttach *att) { - QString dir = KGlobal::dirs()->localkdedir() + "/share/apps/ktnef/tmp/"; + TQString dir = KGlobal::dirs()->localkdedir() + "/share/apps/ktnef/tmp/"; parser_->extractFileTo(att->name(), dir); dir.append(att->name()); return dir; @@ -210,7 +210,7 @@ void KTNEFMain::extractFile() void KTNEFMain::extractFileTo() { - QString dir = KFileDialog::getExistingDirectory(lastdir_, this); + TQString dir = KFileDialog::getExistingDirectory(lastdir_, this); if (!dir.isEmpty()) { extractTo(dir); @@ -220,7 +220,7 @@ void KTNEFMain::extractFileTo() void KTNEFMain::extractAllFiles() { - QString dir = KFileDialog::getExistingDirectory(lastdir_, this); + TQString dir = KFileDialog::getExistingDirectory(lastdir_, this); if (!dir.isEmpty()) { lastdir_ = dir; @@ -230,7 +230,7 @@ void KTNEFMain::extractAllFiles() for (;it.current();++it) if (!parser_->extractFileTo(it.current()->name(), dir)) { - QString msg = i18n( "Unable to extract file \"%1\"" ).arg( it.current()->name() ); + TQString msg = i18n( "Unable to extract file \"%1\"" ).arg( it.current()->name() ); TQMessageBox::critical(this,i18n("Error"),msg,TQMessageBox::Ok|TQMessageBox::Default,0); return; } @@ -247,7 +247,7 @@ void KTNEFMain::propertiesFile() void KTNEFMain::optionDefaultDir() { - QString dirname = KFileDialog::getExistingDirectory(defaultdir_, this); + TQString dirname = KFileDialog::getExistingDirectory(defaultdir_, this); if (!dirname.isEmpty()) { defaultdir_ = dirname; @@ -285,23 +285,23 @@ void KTNEFMain::enableSingleAction(bool on) void KTNEFMain::cleanup() { - QDir d(KGlobal::dirs()->localkdedir() + "/share/apps/ktnef/tmp/"); - const QFileInfoList *list = d.entryInfoList(TQDir::Files|TQDir::Hidden,TQDir::Unsorted); - QFileInfoListIterator it(*list); + TQDir d(KGlobal::dirs()->localkdedir() + "/share/apps/ktnef/tmp/"); + const TQFileInfoList *list = d.entryInfoList(TQDir::Files|TQDir::Hidden,TQDir::Unsorted); + TQFileInfoListIterator it(*list); for (;it.current();++it) d.remove(it.current()->absFilePath()); } void KTNEFMain::extractTo(const TQString& dirname) { - QString dir = dirname; + TQString dir = dirname; if (dir.right(1) != "/") dir.append("/"); TQPtrList<KTNEFAttach> *list = view_->getSelection(); TQPtrListIterator<KTNEFAttach> it(*list); for (;it.current();++it) if (!parser_->extractFileTo(it.current()->name(), dir)) { - QString msg = i18n("Unable to extract file \"%1\"").arg( it.current()->name() ); + TQString msg = i18n("Unable to extract file \"%1\"").arg( it.current()->name() ); TQMessageBox::critical(this,i18n("Error"),msg,TQMessageBox::Ok|TQMessageBox::Default,0); return; } @@ -390,7 +390,7 @@ void KTNEFMain::slotShowMessageText() void KTNEFMain::slotSaveMessageText() { TQString rtf = parser_->message()->rtfString(); - TQString filename = KFileDialog::getSaveFileName( TQString::null, TQString::null, this ); + TQString filename = KFileDialog::getSaveFileName( TQString(), TQString(), this ); if ( !filename.isEmpty() ) { TQFile f( filename ); |