From 769d9f539ffa81925d11cf5480e396d26a43b86d Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Fri, 16 Dec 2011 09:55:55 -0600 Subject: Revert "Rename a number of old tq methods that are no longer tq specific" This reverts commit a3703745120ffe8f1beadd5fa58f9ab1470bc2f8. --- .../catalogs/amarokcatalog/amarokcatalog.cpp | 46 +++++++++++----------- 1 file changed, 23 insertions(+), 23 deletions(-) (limited to 'katapult/plugins/catalogs/amarokcatalog/amarokcatalog.cpp') diff --git a/katapult/plugins/catalogs/amarokcatalog/amarokcatalog.cpp b/katapult/plugins/catalogs/amarokcatalog/amarokcatalog.cpp index 6ad0892..7ca1f9b 100644 --- a/katapult/plugins/catalogs/amarokcatalog/amarokcatalog.cpp +++ b/katapult/plugins/catalogs/amarokcatalog/amarokcatalog.cpp @@ -47,7 +47,7 @@ AmarokCatalog::AmarokCatalog(TQObject*, const char*, const TQStringList&): _resu { _minQueryLen = 3; ActionRegistry::self()->registerAction(new ActionPlaySong()); - _gotCollectionStatus = false; + _gotCollectiontqStatus = false; _dynamicCollection = false; checkCollectionType(); @@ -58,16 +58,16 @@ AmarokCatalog::~AmarokCatalog() void AmarokCatalog::queryChanged() { - int newStatus = 0; + int newtqStatus = 0; TQString queryString = query(); if((TQString(queryString).remove(':').remove('\"').remove(' ').isEmpty()) || (queryString.length() < _minQueryLen)) { reset(); setBestMatch(Match()); - setStatus(0); + settqStatus(0); } else { - if ( _gotCollectionStatus) + if ( _gotCollectiontqStatus) { if (!_dynamicCollection) @@ -89,8 +89,8 @@ void AmarokCatalog::queryChanged() queryList = TQStringList::split ( TQString(" "), TQString(queryString).replace(TQChar(':')," ").replace(TQChar('\''), " ").replace(TQChar('\''), "%") ); for(TQStringList::Iterator it = queryList.begin(); it != queryList.end(); ++it) { - sqlQuery.append(TQString(" AND (t.title LIKE '\%%1\%'").arg(*it)); - sqlQuery.append(TQString(" OR a.name LIKE '\%%1\%')").arg(*it)); + sqlQuery.append(TQString(" AND (t.title LIKE '\%%1\%'").tqarg(*it)); + sqlQuery.append(TQString(" OR a.name LIKE '\%%1\%')").tqarg(*it)); } sqlQuery.append(" ORDER BY a.name, t.title, s.percentage DESC"); @@ -101,7 +101,7 @@ void AmarokCatalog::queryChanged() arg << sqlQuery; if (!kapp->dcopClient()->call("amarok", "collection", "query(TQString)", sqlQueryData, replyType, replyData)) { - newStatus = 0; + newtqStatus = 0; } else { TQDataStream reply(replyData, IO_ReadOnly); if (replyType == TQSTRINGLIST_OBJECT_NAME_STRING) { @@ -109,7 +109,7 @@ void AmarokCatalog::queryChanged() reply >> sqlResult; if(sqlResult.isEmpty()) { - newStatus = 0; + newtqStatus = 0; } else { reset(); //Reads information from SQL-Query @@ -141,12 +141,12 @@ void AmarokCatalog::queryChanged() //Checks if there are multiple results if( !sqlResult[5].isEmpty() ) - newStatus = S_HasResults | S_Multiple; + newtqStatus = S_HasResults | S_Multiple; else - newStatus = S_HasResults; + newtqStatus = S_HasResults; } } else { - newStatus = 0; + newtqStatus = 0; } } @@ -163,8 +163,8 @@ void AmarokCatalog::queryChanged() TQStringList clauses; for(TQStringList::Iterator it = queryList.begin(); it != queryList.end(); ++it) { - clauses += TQString(" (t.title LIKE '\%%1\%'").arg(*it) + - TQString(" OR a.name LIKE '\%%1\%')").arg(*it); + clauses += TQString(" (t.title LIKE '\%%1\%'").tqarg(*it) + + TQString(" OR a.name LIKE '\%%1\%')").tqarg(*it); } sqlQuery.append(clauses.join(TQString(" AND "))); sqlQuery.append(" ORDER BY a.name, t.title, s.percentage DESC"); @@ -176,7 +176,7 @@ void AmarokCatalog::queryChanged() arg << sqlQuery; if (!kapp->dcopClient()->call("amarok", "collection", "query(TQString)", sqlQueryData, replyType, replyData)) { - newStatus = 0; + newtqStatus = 0; } else { TQDataStream reply(replyData, IO_ReadOnly); if (replyType == TQSTRINGLIST_OBJECT_NAME_STRING) { @@ -184,7 +184,7 @@ void AmarokCatalog::queryChanged() reply >> sqlResult; if(sqlResult.isEmpty()) { - newStatus = 0; + newtqStatus = 0; } else { reset(); //Reads information from SQL-Query @@ -231,25 +231,25 @@ void AmarokCatalog::queryChanged() //Checks if there are multiple results if( !sqlResult[7].isEmpty() ) - newStatus = S_HasResults | S_Multiple; + newtqStatus = S_HasResults | S_Multiple; else - newStatus = S_HasResults; + newtqStatus = S_HasResults; } } else { - newStatus = 0; + newtqStatus = 0; } } } //end of >1.4.2 section - setStatus(newStatus); + settqStatus(newtqStatus); } else { //We haven't got the collection status checkCollectionType(); reset(); setBestMatch(Match()); - setStatus(0); + settqStatus(0); } @@ -275,7 +275,7 @@ void AmarokCatalog::checkCollectionType() arg << sqlQuery; if (!kapp->dcopClient()->call("amarok", "collection", "query(TQString)", sqlQueryData, replyType, replyData)) { - _gotCollectionStatus = false; + _gotCollectiontqStatus = false; } else @@ -296,11 +296,11 @@ void AmarokCatalog::checkCollectionType() _dynamicCollection = false; } - _gotCollectionStatus = true; + _gotCollectiontqStatus = true; } else { - _gotCollectionStatus = false; + _gotCollectiontqStatus = false; } } } -- cgit v1.2.1