From 98d15d90b6a83e2df32d678013847e18b8a8c7e8 Mon Sep 17 00:00:00 2001 From: tpearson Date: Sat, 28 May 2011 18:03:09 +0000 Subject: TQt4 port Katapult This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/katapult@1233929 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- .../plugins/catalogs/spellcatalog/spellcatalog.cpp | 30 +++++++++++----------- 1 file changed, 15 insertions(+), 15 deletions(-) (limited to 'katapult/plugins/catalogs/spellcatalog/spellcatalog.cpp') diff --git a/katapult/plugins/catalogs/spellcatalog/spellcatalog.cpp b/katapult/plugins/catalogs/spellcatalog/spellcatalog.cpp index 5cbdbed..cbc3b8b 100644 --- a/katapult/plugins/catalogs/spellcatalog/spellcatalog.cpp +++ b/katapult/plugins/catalogs/spellcatalog/spellcatalog.cpp @@ -29,8 +29,8 @@ #include #include -#include -#include +#include +#include #include "settings.h" #include "spellcatalog.h" @@ -41,7 +41,7 @@ K_EXPORT_COMPONENT_FACTORY( katapult_spellcatalog, KGenericFactory( "katapult_spellcatalog" ) ) -SpellCatalog::SpellCatalog(QObject*, const char*, const QStringList&): _result(this, QString::null) +SpellCatalog::SpellCatalog(TQObject*, const char*, const TQStringList&): _result(this, TQString()) { ActionRegistry::self()->registerAction(new ActionCopySpelling()); } @@ -52,8 +52,8 @@ SpellCatalog::~SpellCatalog() void SpellCatalog::queryChanged() { - int newStatus = 0; - QString cmd = query(); + int newtqStatus = 0; + TQString cmd = query(); int origLength = cmd.length(); if (cmd.isEmpty()) { @@ -67,15 +67,15 @@ void SpellCatalog::queryChanged() //set status. //add S_Multiple to make sure katapult doesn't auto-exec and close the window //add S_Active to make sure katapult doesn't start the hideTimer or clearTimer - newStatus = S_HasResults | S_Multiple | S_Active; + newtqStatus = S_HasResults | S_Multiple | S_Active; } else { - newStatus = 0; + newtqStatus = 0; } } - setStatus(newStatus); + settqStatus(newtqStatus); } -bool SpellCatalog::accepts(const QString& str) const +bool SpellCatalog::accepts(const TQString& str) const { //accept if we begin with the triggerWord int length = _triggerWord.length(); @@ -92,21 +92,21 @@ void SpellCatalog::writeSettings(KConfigBase* config) config->writeEntry("TriggerWord", _triggerWord); } -QWidget * SpellCatalog::configure() +TQWidget * SpellCatalog::configure() { SpellCatalogSettings* settings = new SpellCatalogSettings(); settings->triggerWordLE->setText(_triggerWord); - connect(settings->triggerWordLE, SIGNAL(textChanged(const QString&)), this, SLOT(triggerWordChanged(const QString&))); + connect(settings->triggerWordLE, TQT_SIGNAL(textChanged(const TQString&)), this, TQT_SLOT(triggerWordChanged(const TQString&))); - settings->introLabel->setText(i18n("Use with \"%1 myword\"").arg(_triggerWord)); + settings->introLabel->setText(i18n("Use with \"%1 myword\"").tqarg(_triggerWord)); return settings; } -void SpellCatalog::triggerWordChanged(const QString& triggerWord) +void SpellCatalog::triggerWordChanged(const TQString& triggerWord) { - _triggerWord = QString(triggerWord); + _triggerWord = TQString(triggerWord); } int SpellCatalog::triggerWordLength() @@ -116,7 +116,7 @@ int SpellCatalog::triggerWordLength() void SpellCatalog::reset() { - _result.setText(QString::null); + _result.setText(TQString()); } #include "spellcatalog.moc" -- cgit v1.2.1