From e192d1b3be27a26e344ae48cc6aea31185fe0a99 Mon Sep 17 00:00:00 2001 From: tpearson Date: Mon, 13 Jun 2011 00:26:14 +0000 Subject: Finish TQt4 porting of kdesdk (kbabel) git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdesdk@1236386 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kbabel/kbabeldict/dictchooser.cpp | 2 +- kbabel/kbabeldict/kbabeldictbox.cpp | 14 +++++------ .../modules/dbsearchengine/KDBSearchEngine.cpp | 10 ++++---- .../kbabeldict/modules/dbsearchengine/database.cpp | 4 ++-- .../kbabeldict/modules/dbsearchengine/dbscan.cpp | 2 +- .../kbabeldict/modules/poauxiliary/poauxiliary.cpp | 6 ++--- kbabel/kbabeldict/modules/poauxiliary/pwidget.ui | 8 +++---- .../modules/pocompendium/compendiumdata.cpp | 4 ++-- .../modules/pocompendium/pocompendium.cpp | 6 ++--- kbabel/kbabeldict/modules/pocompendium/pwidget.ui | 28 +++++++++++----------- kbabel/kbabeldict/modules/tmx/tmxcompendium.cpp | 6 ++--- .../kbabeldict/modules/tmx/tmxcompendiumdata.cpp | 4 ++-- 12 files changed, 47 insertions(+), 47 deletions(-) (limited to 'kbabel/kbabeldict') diff --git a/kbabel/kbabeldict/dictchooser.cpp b/kbabel/kbabeldict/dictchooser.cpp index d60b1de6..ec7ba712 100644 --- a/kbabel/kbabeldict/dictchooser.cpp +++ b/kbabel/kbabeldict/dictchooser.cpp @@ -261,7 +261,7 @@ bool DictChooser::eventFilter(TQObject *object, TQEvent *event) { if(event->type() == TQEvent::FocusIn) { - if(object==selectedBox) + if(TQT_BASE_OBJECT(object)==TQT_BASE_OBJECT(selectedBox)) { int i = selectedBox->currentItem(); selectedBox->setSelected(i,true); diff --git a/kbabel/kbabeldict/kbabeldictbox.cpp b/kbabel/kbabeldict/kbabeldictbox.cpp index 4f1a4f7f..bd2fbbcd 100644 --- a/kbabel/kbabeldict/kbabeldictbox.cpp +++ b/kbabel/kbabeldict/kbabeldictbox.cpp @@ -388,7 +388,7 @@ KBabelDictBox::KBabelDictBox( TQWidget* tqparent, const char* name, WFlags fl ) if(factory) { - SearchEngine *e = (SearchEngine *)factory->create(this + SearchEngine *e = (SearchEngine *)factory->create(TQT_TQOBJECT(this) , "searchengine", "SearchEngine"); if(!e) { @@ -419,7 +419,7 @@ KBabelDictBox::KBabelDictBox( TQWidget* tqparent, const char* name, WFlags fl ) if(factory) { - SearchEngine *e = (SearchEngine *)factory->create(this + SearchEngine *e = (SearchEngine *)factory->create(TQT_TQOBJECT(this) , "searchengine", "SearchEngine"); if(!e) { @@ -447,7 +447,7 @@ KBabelDictBox::KBabelDictBox( TQWidget* tqparent, const char* name, WFlags fl ) if(factory) { - SearchEngine *e = (SearchEngine *)factory->create(this + SearchEngine *e = (SearchEngine *)factory->create(TQT_TQOBJECT(this) , "searchengine", "SearchEngine"); if(!e) { @@ -1534,7 +1534,7 @@ void KBabelDictBox::configure(const TQString& id, bool modal) void KBabelDictBox::destroyConfigDialog() { - const TQObject *obj = sender(); + const TQObject *obj = TQT_TQOBJECT(const_cast(sender())); if(obj && obj->inherits("KDialogBase")) { KDialogBase *dialog = (KDialogBase*)obj; @@ -1609,14 +1609,14 @@ bool KBabelDictBox::eventFilter(TQObject *o, TQEvent *e) { if(e->type() == TQEvent::Wheel) { - TQWheelEvent *we = static_cast(e); + TQWheelEvent *we = TQT_TQWHEELEVENT(e); if(we) { wheelEvent(we); return true; } } - else if(e->type() == TQEvent::Resize && o == resultListView) + else if(e->type() == TQEvent::Resize && TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(resultListView)) { if(resultListView->height() < 2) { @@ -1679,7 +1679,7 @@ void KBabelDictBox::editFile() DCOPClient *dcop = kapp->dcopClient(); QCStringList list = dcop->registeredApplications(); - int index = list.findIndex("kbabel"); + int index = list.tqfindIndex("kbabel"); if(index < 0) // if(!dcop->isApplicationRegistered("kbabel")); { diff --git a/kbabel/kbabeldict/modules/dbsearchengine/KDBSearchEngine.cpp b/kbabel/kbabeldict/modules/dbsearchengine/KDBSearchEngine.cpp index 3e658255..3292ccc9 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine/KDBSearchEngine.cpp +++ b/kbabel/kbabeldict/modules/dbsearchengine/KDBSearchEngine.cpp @@ -474,7 +474,7 @@ KDBSearchEngine::messagesForFilter (const SearchFilter * filter, if (count % step == 0) { emit progress (100 * count / totalRecord); - kapp->processEvents (100); + kapp->tqprocessEvents (100); } if (stopNow) { @@ -582,7 +582,7 @@ KDBSearchEngine::repeat () if (count % step == 0) { emit progress (100 * count / totalRecord); - kapp->processEvents (100); + kapp->tqprocessEvents (100); } if (stopNow) { @@ -755,7 +755,7 @@ KDBSearchEngine::startSearchNow (int searchmode) step = 100; emit progress (0); - kapp->processEvents (100); + kapp->tqprocessEvents (100); if (stopNow) { stopNow = false; @@ -775,7 +775,7 @@ KDBSearchEngine::startSearchNow (int searchmode) { emit progress (100 * count / /*TQMAX( */ totalprogress /*,1) */ ); - kapp->processEvents (100); + kapp->tqprocessEvents (100); if (stopNow) { @@ -1715,7 +1715,7 @@ TQValueList < KeyAndScore > KDBSearchEngine::searchWords (TQString phrase, { emit progress (100 * count / totalprogress); - kapp->processEvents (100); + kapp->tqprocessEvents (100); } if (stopNow) { diff --git a/kbabel/kbabeldict/modules/dbsearchengine/database.cpp b/kbabel/kbabeldict/modules/dbsearchengine/database.cpp index cb5ebae1..1d1cb9ae 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine/database.cpp +++ b/kbabel/kbabeldict/modules/dbsearchengine/database.cpp @@ -703,7 +703,7 @@ DataBaseManager::cursorGet (uint32 flags) else { kdDebug (KBABEL_SEARCH) << TQString ("...cursor getting...%1"). - arg (ret) << endl; + tqarg (ret) << endl; return DataBaseItem (); } @@ -861,7 +861,7 @@ DataBaseManager::createDataBase (TQString directory, loadInfo (); else kdDebug (KBABEL_SEARCH) << TQString ("I am NOT ok : %1"). - arg (ret) << endl; + tqarg (ret) << endl; //THIS IS WRONG, rewrite the error handling. return iAmOk; diff --git a/kbabel/kbabeldict/modules/dbsearchengine/dbscan.cpp b/kbabel/kbabeldict/modules/dbsearchengine/dbscan.cpp index fd3ed7f1..3d86ebb1 100644 --- a/kbabel/kbabeldict/modules/dbsearchengine/dbscan.cpp +++ b/kbabel/kbabeldict/modules/dbsearchengine/dbscan.cpp @@ -159,7 +159,7 @@ for (i=0;iprocessEvents(100); + kapp->tqprocessEvents(100); } fuzzy=catalog->isFuzzy(i); diff --git a/kbabel/kbabeldict/modules/poauxiliary/poauxiliary.cpp b/kbabel/kbabeldict/modules/poauxiliary/poauxiliary.cpp index cc726ad8..fae9fb0e 100644 --- a/kbabel/kbabeldict/modules/poauxiliary/poauxiliary.cpp +++ b/kbabel/kbabeldict/modules/poauxiliary/poauxiliary.cpp @@ -182,7 +182,7 @@ bool PoAuxiliary::startSearch(const TQString& t, uint pluralForm, const SearchFi clearResults(); - kapp->processEvents(100); + kapp->tqprocessEvents(100); text.tqreplace("\n",""); @@ -255,7 +255,7 @@ bool PoAuxiliary::startSearchInTranslation(const TQString& text) clearResults(); - kapp->processEvents(100); + kapp->tqprocessEvents(100); Entry *entry = msgstrDict[text]; if(entry) @@ -455,7 +455,7 @@ void PoAuxiliary::loadAuxiliary() if( (100*(i+1))%total < 100 ) { emit progress((100*(i+1))/total); - kapp->processEvents(100); + kapp->tqprocessEvents(100); } Entry *e = new Entry; diff --git a/kbabel/kbabeldict/modules/poauxiliary/pwidget.ui b/kbabel/kbabeldict/modules/poauxiliary/pwidget.ui index aa9e6710..b91f98e5 100644 --- a/kbabel/kbabeldict/modules/poauxiliary/pwidget.ui +++ b/kbabel/kbabeldict/modules/poauxiliary/pwidget.ui @@ -1,7 +1,7 @@ PWidget - QWidget + TQWidget name PWidget @@ -29,7 +29,7 @@ 6 - QLabel + TQLabel name TextLabel1 @@ -51,7 +51,7 @@ - QCheckBox + TQCheckBox name fuzzyBtn @@ -62,7 +62,7 @@ - QLabel + TQLabel name TextLabel1_2 diff --git a/kbabel/kbabeldict/modules/pocompendium/compendiumdata.cpp b/kbabel/kbabeldict/modules/pocompendium/compendiumdata.cpp index f5c37dd5..edc38dc0 100644 --- a/kbabel/kbabeldict/modules/pocompendium/compendiumdata.cpp +++ b/kbabel/kbabeldict/modules/pocompendium/compendiumdata.cpp @@ -109,7 +109,7 @@ bool CompendiumData::load(KURL url) if( (100*(i+1))%total < 100 ) { emit progress((100*(i+1))/total); - kapp->processEvents(100); + kapp->tqprocessEvents(100); } // FIXME: shoudl care about plural forms @@ -221,7 +221,7 @@ const TQValueList* CompendiumData::textonlyDict(const TQString text) const void CompendiumData::registerObject(TQObject *obj) { - if(!_registered.containsRef(obj)) + if(!_registered.tqcontainsRef(obj)) _registered.append(obj); } diff --git a/kbabel/kbabeldict/modules/pocompendium/pocompendium.cpp b/kbabel/kbabeldict/modules/pocompendium/pocompendium.cpp index 1911be72..dab127bf 100644 --- a/kbabel/kbabeldict/modules/pocompendium/pocompendium.cpp +++ b/kbabel/kbabeldict/modules/pocompendium/pocompendium.cpp @@ -369,7 +369,7 @@ bool PoCompendium::searchWords(const TQString& searchStr, uint pluralForm, TQPtr emit progress( (50*checkCounter+1)/catalogInfo.total); } - kapp->processEvents(100); + kapp->tqprocessEvents(100); TQString origStr = data->catalog()->msgid(*it).first(); origStr = CompendiumData::simplify(origStr); @@ -537,7 +537,7 @@ bool PoCompendium::searchNGram(const TQString& searchStr, uint pluralForm, TQPtr continue; } - kapp->processEvents(100); + kapp->tqprocessEvents(100); TQString origStr = data->catalog()->msgid(i).first(); origStr = CompendiumData::simplify(origStr); @@ -1204,7 +1204,7 @@ void PoCompendium::registerData() void PoCompendium::removeData() { - const TQObject *s=sender(); + const TQObject *s=TQT_TQOBJECT(const_cast(sender())); if(s && s->inherits("CompendiumData")) { const CompendiumData *d=static_cast(s); diff --git a/kbabel/kbabeldict/modules/pocompendium/pwidget.ui b/kbabel/kbabeldict/modules/pocompendium/pwidget.ui index f1883a88..f9558dc3 100644 --- a/kbabel/kbabeldict/modules/pocompendium/pwidget.ui +++ b/kbabel/kbabeldict/modules/pocompendium/pwidget.ui @@ -2,7 +2,7 @@ CompendiumPWidget kseparator.h - QWidget + TQWidget name PWidget @@ -30,7 +30,7 @@ 6 - QGroupBox + TQGroupBox name GroupBox1 @@ -58,7 +58,7 @@ - QButtonGroup + TQButtonGroup name ButtonGroup1 @@ -77,7 +77,7 @@ 6 - QLayoutWidget + TQLayoutWidget name Layout4 @@ -92,7 +92,7 @@ 6 - QCheckBox + TQCheckBox name fuzzyBtn @@ -103,7 +103,7 @@ - QCheckBox + TQCheckBox name wholeBtn @@ -114,7 +114,7 @@ - QCheckBox + TQCheckBox name caseBtn @@ -138,7 +138,7 @@ - QLabel + TQLabel name TextLabel3 @@ -149,7 +149,7 @@ - QLayoutWidget + TQLayoutWidget name Layout3 @@ -164,7 +164,7 @@ 6 - QCheckBox + TQCheckBox name equalBtn @@ -175,7 +175,7 @@ - QCheckBox + TQCheckBox name hasWordBtn @@ -186,7 +186,7 @@ - QCheckBox + TQCheckBox name isContainedBtn @@ -197,7 +197,7 @@ - QCheckBox + TQCheckBox name ngramBtn @@ -208,7 +208,7 @@ - QCheckBox + TQCheckBox name containsBtn diff --git a/kbabel/kbabeldict/modules/tmx/tmxcompendium.cpp b/kbabel/kbabeldict/modules/tmx/tmxcompendium.cpp index fd5fcd29..f375574c 100644 --- a/kbabel/kbabeldict/modules/tmx/tmxcompendium.cpp +++ b/kbabel/kbabeldict/modules/tmx/tmxcompendium.cpp @@ -337,7 +337,7 @@ bool TmxCompendium::startSearch(const TQString& text, uint pluralForm, const Sea emit progress( (100*(checkCounter+1))/data->numberOfEntries()); } - kapp->processEvents(100); + kapp->tqprocessEvents(100); TQString origStr = data->msgid(*it); origStr = TmxCompendiumData::simplify(origStr); @@ -484,7 +484,7 @@ bool TmxCompendium::startSearch(const TQString& text, uint pluralForm, const Sea continue; } - kapp->processEvents(100); + kapp->tqprocessEvents(100); if(i >= data->numberOfEntries()) { @@ -965,7 +965,7 @@ void TmxCompendium::registerData() void TmxCompendium::removeData() { - const TQObject *s=sender(); + const TQObject *s=TQT_TQOBJECT(const_cast(sender())); if(s && s->inherits("TmxCompendiumData")) { const TmxCompendiumData *d=static_cast(s); diff --git a/kbabel/kbabeldict/modules/tmx/tmxcompendiumdata.cpp b/kbabel/kbabeldict/modules/tmx/tmxcompendiumdata.cpp index 739379e1..1cd033bc 100644 --- a/kbabel/kbabeldict/modules/tmx/tmxcompendiumdata.cpp +++ b/kbabel/kbabeldict/modules/tmx/tmxcompendiumdata.cpp @@ -146,7 +146,7 @@ bool TmxCompendiumData::load(const KURL& url, const TQString& language) if( (100*(i+1))%total < 100 ) { emit progress((100*(i+1))/total); - kapp->processEvents(100); + kapp->tqprocessEvents(100); } TQDomNodeList tuvTags = tuTags.item(i).toElement().elementsByTagName("tuv"); @@ -268,7 +268,7 @@ const TQString TmxCompendiumData::msgstr(const int index) const void TmxCompendiumData::registerObject(TQObject *obj) { - if(!_registered.containsRef(obj)) + if(!_registered.tqcontainsRef(obj)) _registered.append(obj); } -- cgit v1.2.1