summaryrefslogtreecommitdiffstats
path: root/kbugbuster
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-10 06:08:18 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-10 06:08:18 +0000
commit0813b39aed2cf4c84157a22c4c9594336d93d412 (patch)
tree0f6157f9c9ecc6ed26cb98f058219a8021d3f4a6 /kbugbuster
parent35dc58791106d7a1864264063df5f3ee3f1f0f15 (diff)
downloadtdesdk-0813b39aed2cf4c84157a22c4c9594336d93d412.tar.gz
tdesdk-0813b39aed2cf4c84157a22c4c9594336d93d412.zip
rename the following methods:
tqfind find tqreplace replace tqcontains contains git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdesdk@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kbugbuster')
-rw-r--r--kbugbuster/backend/bugcache.cpp2
-rw-r--r--kbugbuster/backend/bugdetails.cpp4
-rw-r--r--kbugbuster/backend/bugserver.cpp4
-rw-r--r--kbugbuster/backend/domprocessor.cpp4
-rw-r--r--kbugbuster/backend/htmlparser.cpp32
-rw-r--r--kbugbuster/backend/person.cpp16
-rw-r--r--kbugbuster/gui/centralwidget.cpp4
-rw-r--r--kbugbuster/gui/cwbuglistcontainer.cpp24
-rw-r--r--kbugbuster/gui/cwbuglistcontainer.h2
-rw-r--r--kbugbuster/gui/kbbmainwindow.cpp4
-rw-r--r--kbugbuster/gui/messageeditor.cpp2
-rw-r--r--kbugbuster/gui/packageselectdialog.cpp2
12 files changed, 50 insertions, 50 deletions
diff --git a/kbugbuster/backend/bugcache.cpp b/kbugbuster/backend/bugcache.cpp
index b2d13814..4650c9fe 100644
--- a/kbugbuster/backend/bugcache.cpp
+++ b/kbugbuster/backend/bugcache.cpp
@@ -59,7 +59,7 @@ Package::List BugCache::loadPackageList()
TQStringList::ConstIterator it;
for( it = packages.begin(); it != packages.end(); ++it ) {
if ((*it) == "<default>") continue;
- if ((*it).tqcontains("/")) continue;
+ if ((*it).contains("/")) continue;
m_cachePackages->setGroup(*it);
diff --git a/kbugbuster/backend/bugdetails.cpp b/kbugbuster/backend/bugdetails.cpp
index 5dcfbcd4..cebcedd3 100644
--- a/kbugbuster/backend/bugdetails.cpp
+++ b/kbugbuster/backend/bugdetails.cpp
@@ -181,7 +181,7 @@ TQValueList<BugDetails::Attachment> BugDetails::extractAttachments( const TQStri
kdDebug() << "BugDetails::extractAttachments found header " << *rit << endl;
#endif
// Taken from libkdenetwork/kmime_headers.cpp
- int pos=header.tqfind("filename=", 0, false);
+ int pos=header.find("filename=", 0, false);
TQString fn;
if(pos>-1) {
pos+=9;
@@ -231,7 +231,7 @@ TQValueList<BugDetails::Attachment> BugDetails::extractAttachments( const TQStri
}
contents += line; // no newline, because of linebreaking between <br and />
}
- contents = contents.tqreplace( TQRegExp("<br */>"), TQString() );
+ contents = contents.replace( TQRegExp("<br */>"), TQString() );
#ifdef DEBUG_EXTRACT
kdDebug() << "BugDetails::extractAttachments contents=***\n" << contents << "\n***" << endl;
#endif
diff --git a/kbugbuster/backend/bugserver.cpp b/kbugbuster/backend/bugserver.cpp
index 37089623..a1863f58 100644
--- a/kbugbuster/backend/bugserver.cpp
+++ b/kbugbuster/backend/bugserver.cpp
@@ -216,14 +216,14 @@ bool BugServer::queueCommand( BugCommand *cmd )
TQPtrList<BugCommand> BugServer::queryCommands( const Bug &bug ) const
{
- CommandsMap::ConstIterator it = mCommands.tqfind( bug.number() );
+ CommandsMap::ConstIterator it = mCommands.find( bug.number() );
if (it == mCommands.end()) return TQPtrList<BugCommand>();
else return *it;
}
bool BugServer::hasCommandsFor( const Bug &bug ) const
{
- CommandsMap::ConstIterator it = mCommands.tqfind( bug.number() );
+ CommandsMap::ConstIterator it = mCommands.find( bug.number() );
return it != mCommands.end();
}
diff --git a/kbugbuster/backend/domprocessor.cpp b/kbugbuster/backend/domprocessor.cpp
index 9b5c2944..e7b1e49c 100644
--- a/kbugbuster/backend/domprocessor.cpp
+++ b/kbugbuster/backend/domprocessor.cpp
@@ -273,7 +273,7 @@ KBB::Error DomProcessor::parseDomBugDetails( const TQDomElement &element,
text += raw;
}
TQString bugBaseURL = server()->serverConfig().baseUrl().htmlURL();
- text = "<pre>" + wrapLines( text ).tqreplace( TQRegExp( "(Created an attachment \\(id=([0-9]+)\\))" ),
+ text = "<pre>" + wrapLines( text ).replace( TQRegExp( "(Created an attachment \\(id=([0-9]+)\\))" ),
"<a href=\"" + bugBaseURL + "/attachment.cgi?id=\\2&action=view\">\\1</a>" ) + "\n</pre>";
}
}
@@ -361,7 +361,7 @@ TQString DomProcessor::wrapLines( const TQString &text )
TQString wrappedLine;
while ( line.length() > uint( wrap ) )
{
- int breakPoint = line.tqfindRev( ' ', wrap );
+ int breakPoint = line.findRev( ' ', wrap );
//kdDebug() << "Breaking at " << breakPoint << endl;
if( breakPoint == -1 ) {
wrappedLine += line.left( wrap ) + '\n';
diff --git a/kbugbuster/backend/htmlparser.cpp b/kbugbuster/backend/htmlparser.cpp
index e9840e6b..4daa3d1d 100644
--- a/kbugbuster/backend/htmlparser.cpp
+++ b/kbugbuster/backend/htmlparser.cpp
@@ -100,10 +100,10 @@ void HtmlParser::processResult( Package::List & )
TQString HtmlParser::getAttribute( const TQString &line, const TQString &name )
{
- int pos1 = line.tqfind( name + "=\"" );
+ int pos1 = line.find( name + "=\"" );
if ( pos1 < 1 ) return TQString();
pos1 += name.length() + 2;
- int pos2 = line.tqfind( "\"", pos1 );
+ int pos2 = line.find( "\"", pos1 );
if ( pos2 < 1 ) return TQString();
return line.mid( pos1, pos2 - pos1 );
}
@@ -111,24 +111,24 @@ TQString HtmlParser::getAttribute( const TQString &line, const TQString &name )
bool HtmlParser::getCpts( const TQString &line, TQString &key,
TQStringList &values )
{
- if ( !line.tqcontains( TQRegExp( "\\s*cpts" ) ) ) return false;
+ if ( !line.contains( TQRegExp( "\\s*cpts" ) ) ) return false;
// kdDebug() << "LINE: " << line << endl;
- int pos1 = line.tqfind( "[" );
+ int pos1 = line.find( "[" );
if ( pos1 < 0 ) return false;
- int pos2 = line.tqfind( "]", ++pos1 );
+ int pos2 = line.find( "]", ++pos1 );
if ( pos2 < 0 ) return false;
key = line.mid( pos1, pos2 - pos1 );
- int pos3 = key.tqfind( "'" );
+ int pos3 = key.find( "'" );
if ( pos3 >= 0 ) {
- int pos4 = key.tqfind( "'", ++pos3 );
+ int pos4 = key.find( "'", ++pos3 );
if ( pos4 >= 0 ) key = key.mid( pos3, pos4 - pos3 );
}
// kdDebug() << " KEY: " << key << endl;
- pos1 = line.tqfind( "'", ++pos2 );
- if ( pos1 >= 0 ) pos2 = line.tqfind( "'", ++pos1 );
+ pos1 = line.find( "'", ++pos2 );
+ if ( pos1 >= 0 ) pos2 = line.find( "'", ++pos1 );
while ( pos1 >= 0 && pos2 >= 0 ) {
TQString value = line.mid( pos1, pos2 - pos1 );
@@ -136,8 +136,8 @@ bool HtmlParser::getCpts( const TQString &line, TQString &key,
values.append( value );
- pos1 = line.tqfind( "'", ++pos2 );
- if ( pos1 >= 0 ) pos2 = line.tqfind( "'", ++pos1 );
+ pos1 = line.find( "'", ++pos2 );
+ if ( pos1 >= 0 ) pos2 = line.find( "'", ++pos1 );
}
return true;
@@ -153,7 +153,7 @@ KBB::Error HtmlParser_2_10::parseLine( const TQString &line, Bug::List &bugs )
// kdDebug() << " NUMBER: " << number << endl;
TQString summary;
- int pos = line.tqfindRev( "summary>" );
+ int pos = line.findRev( "summary>" );
if ( pos >= 0 ) summary = line.mid( pos + 8 );
Bug bug( new BugImpl( summary, Person(), number, 0xFFFFFFFF, Bug::SeverityUndefined,
@@ -248,13 +248,13 @@ KBB::Error HtmlParser_2_17_1::parseLine( const TQString &line, Package::List & )
switch ( mState ) {
case Idle:
case SearchComponents:
- if ( line.tqcontains( "var cpts" ) ) mState = Components;
+ if ( line.contains( "var cpts" ) ) mState = Components;
break;
case SearchProducts:
- if ( line.tqcontains( "onchange=\"selectProduct" ) ) mState = Products;
+ if ( line.contains( "onchange=\"selectProduct" ) ) mState = Products;
break;
case Components: {
- if ( line.tqcontains( TQRegExp( "\\s*function" ) ) ) {
+ if ( line.contains( TQRegExp( "\\s*function" ) ) ) {
mState = SearchProducts;
}
TQString key;
@@ -264,7 +264,7 @@ KBB::Error HtmlParser_2_17_1::parseLine( const TQString &line, Package::List & )
}
}
case Products: {
- if ( line.tqcontains( "</select>" ) ) mState = Finished;
+ if ( line.contains( "</select>" ) ) mState = Finished;
TQString product = getAttribute( line, "value" );
if ( !product.isEmpty() ) {
kdDebug() << "PRODUCT: " << product << endl;
diff --git a/kbugbuster/backend/person.cpp b/kbugbuster/backend/person.cpp
index 368ea07c..8f73c512 100644
--- a/kbugbuster/backend/person.cpp
+++ b/kbugbuster/backend/person.cpp
@@ -4,7 +4,7 @@
Person::Person( const TQString &fullName )
{
- int emailPos = fullName.tqfind( '<' );
+ int emailPos = fullName.find( '<' );
if ( emailPos < 0 ) {
email = fullName;
} else {
@@ -41,10 +41,10 @@ Person Person::parseFromString( const TQString &_str )
TQString str = _str;
- int ltPos = str.tqfind( '<' );
+ int ltPos = str.find( '<' );
if ( ltPos != -1 )
{
- int gtPos = str.tqfind( '>', ltPos );
+ int gtPos = str.find( '>', ltPos );
if ( gtPos != -1 )
{
res.name = str.left( ltPos - 1 );
@@ -52,16 +52,16 @@ Person Person::parseFromString( const TQString &_str )
}
}
- int atPos = str.tqfind( '@' );
- int spacedAtPos = str.tqfind( TQString::tqfromLatin1( " at " ) );
+ int atPos = str.find( '@' );
+ int spacedAtPos = str.find( TQString::tqfromLatin1( " at " ) );
if ( atPos == -1 && spacedAtPos != -1 )
- str.tqreplace( spacedAtPos, 4, TQString::tqfromLatin1( "@" ) );
+ str.replace( spacedAtPos, 4, TQString::tqfromLatin1( "@" ) );
- int spacePos = str.tqfind( ' ' );
+ int spacePos = str.find( ' ' );
while ( spacePos != -1 )
{
str[ spacePos ] = '.';
- spacePos = str.tqfind( ' ', spacePos );
+ spacePos = str.find( ' ', spacePos );
}
res.email = str;
diff --git a/kbugbuster/gui/centralwidget.cpp b/kbugbuster/gui/centralwidget.cpp
index 1813d627..2c715bc1 100644
--- a/kbugbuster/gui/centralwidget.cpp
+++ b/kbugbuster/gui/centralwidget.cpp
@@ -340,11 +340,11 @@ void CentralWidget::slotExtractAttachments()
for ( TQValueList<BugDetails::Attachment>::Iterator it = attachments.begin() ; it != attachments.end() ; ++it )
{
// Handle duplicates
- if ( fileList.tqcontains( (*it).filename ) )
+ if ( fileList.contains( (*it).filename ) )
{
int n = 2; // looks stupid to have "blah" and "1-blah", start at 2
TQString fn = TQString::number(n) + '-' + (*it).filename;
- while ( fileList.tqcontains( fn ) )
+ while ( fileList.contains( fn ) )
{
++n;
fn = TQString::number(n) + '-' + (*it).filename;
diff --git a/kbugbuster/gui/cwbuglistcontainer.cpp b/kbugbuster/gui/cwbuglistcontainer.cpp
index edcc442d..fc496a9b 100644
--- a/kbugbuster/gui/cwbuglistcontainer.cpp
+++ b/kbugbuster/gui/cwbuglistcontainer.cpp
@@ -42,7 +42,7 @@
using namespace KBugBusterMainWindow;
CWBugListContainer::CWBugListContainer( TQWidget *tqparent , const char * name )
- : TQWidget( tqparent, name ), m_tqfind(0), m_findItem(0)
+ : TQWidget( tqparent, name ), m_find(0), m_findItem(0)
{
TQBoxLayout *topLayout = new TQVBoxLayout( this );
topLayout->setSpacing( KDialog::spacingHint() );
@@ -114,7 +114,7 @@ CWBugListContainer::~CWBugListContainer()
{
m_listBugs->saveLayout( KBBPrefs::instance()->config(), "BugListLayout" );
KBBPrefs::instance()->writeConfig();
- delete m_tqfind;
+ delete m_find;
}
void CWBugListContainer::setBugList( const TQString &label, const Bug::List &bugs )
@@ -258,12 +258,12 @@ void CWBugListContainer::clearCommand( const TQString &bug )
void CWBugListContainer::searchBugByTitle( int options, const TQString& pattern )
{
- m_tqfind = new KFind( pattern, options, this );
+ m_find = new KFind( pattern, options, this );
// Connect signals to code which handles highlighting
// of found text.
- connect(m_tqfind, TQT_SIGNAL( highlight( const TQString &, int, int ) ),
+ connect(m_find, TQT_SIGNAL( highlight( const TQString &, int, int ) ),
this, TQT_SLOT( searchHighlight( const TQString &, int, int ) ) );
- connect(m_tqfind, TQT_SIGNAL( findNext() ), this, TQT_SLOT( slotFindNext() ) );
+ connect(m_find, TQT_SIGNAL( findNext() ), this, TQT_SLOT( slotFindNext() ) );
m_findItem = (BugLVI *)m_listBugs->firstChild();
if ( options & KFindDialog::FromCursor && m_listBugs->currentItem() )
@@ -279,26 +279,26 @@ void CWBugListContainer::slotFindNext()
KFind::Result res = KFind::NoMatch;
while( res == KFind::NoMatch && m_findItem ) {
- if ( m_tqfind->needData() )
- m_tqfind->setData( m_findItem->text(2) );
+ if ( m_find->needData() )
+ m_find->setData( m_findItem->text(2) );
// Let KFind inspect the text fragment, and display a dialog if a match is found
- res = m_tqfind->find();
+ res = m_find->find();
if ( res == KFind::NoMatch ) {
- if ( m_tqfind->options() & KFindDialog::FindBackwards )
+ if ( m_find->options() & KFindDialog::FindBackwards )
m_findItem = (BugLVI *)m_findItem->itemAbove();
else
m_findItem = (BugLVI *)m_findItem->itemBelow();
}
}
if ( res == KFind::NoMatch ) // i.e. at end
- if ( m_tqfind->shouldRestart() ) {
+ if ( m_find->shouldRestart() ) {
m_findItem = (BugLVI *)m_listBugs->firstChild();
slotFindNext();
} else {
- delete m_tqfind;
- m_tqfind = 0L;
+ delete m_find;
+ m_find = 0L;
}
}
diff --git a/kbugbuster/gui/cwbuglistcontainer.h b/kbugbuster/gui/cwbuglistcontainer.h
index 0144dd57..878b0a2b 100644
--- a/kbugbuster/gui/cwbuglistcontainer.h
+++ b/kbugbuster/gui/cwbuglistcontainer.h
@@ -86,7 +86,7 @@ private:
TQWidgetStack *m_listStack;
KListView *m_listBugs;
- KFind *m_tqfind;
+ KFind *m_find;
BugLVI *m_findItem;
CWLoadingWidget *m_listLoading;
diff --git a/kbugbuster/gui/kbbmainwindow.cpp b/kbugbuster/gui/kbbmainwindow.cpp
index 67b3388c..c351b68e 100644
--- a/kbugbuster/gui/kbbmainwindow.cpp
+++ b/kbugbuster/gui/kbbmainwindow.cpp
@@ -170,11 +170,11 @@ void KBBMainWindow::initActions()
new KAction( i18n("&Search by Product..."), "goto", CTRL+TQt::Key_P, TQT_TQOBJECT(this),
TQT_SLOT( searchPackage() ), actionCollection(), "search_package" );
- new KAction( i18n("Search by Bug &Number..."), "filetqfind", CTRL+TQt::Key_N, TQT_TQOBJECT(this),
+ new KAction( i18n("Search by Bug &Number..."), "filefind", CTRL+TQt::Key_N, TQT_TQOBJECT(this),
TQT_SLOT( searchBugNumber() ), actionCollection(), "search_bugnumber" );
// For now "Description" searches by title. Maybe later we can have a
// full-text search interfacing bugs.kde.org and rename the current one to "By Title".
- new KAction( i18n("Search by &Description...") ,"tqfind", CTRL+TQt::Key_D, TQT_TQOBJECT(this),
+ new KAction( i18n("Search by &Description...") ,"find", CTRL+TQt::Key_D, TQT_TQOBJECT(this),
TQT_SLOT( searchDescription() ), actionCollection(), "search_description" );
// new KAction( i18n("&Merge"), "view_remove", CTRL+TQt::Key_M, TQT_TQOBJECT(m_mainWidget),
diff --git a/kbugbuster/gui/messageeditor.cpp b/kbugbuster/gui/messageeditor.cpp
index 5ef266ff..df9ca4e1 100644
--- a/kbugbuster/gui/messageeditor.cpp
+++ b/kbugbuster/gui/messageeditor.cpp
@@ -105,7 +105,7 @@ void MessageEditor::updateMessage()
void MessageEditor::saveMessage()
{
- mMessageButtons.tqreplace(mCurrentButton,mMessageEdit->text());
+ mMessageButtons.replace(mCurrentButton,mMessageEdit->text());
}
void MessageEditor::slotOk()
diff --git a/kbugbuster/gui/packageselectdialog.cpp b/kbugbuster/gui/packageselectdialog.cpp
index e3481c0b..98cb1ece 100644
--- a/kbugbuster/gui/packageselectdialog.cpp
+++ b/kbugbuster/gui/packageselectdialog.cpp
@@ -169,7 +169,7 @@ void PackageSelectDialog::slotOk()
BugServer *server = BugSystem::self()->server();
TQStringList recent = server->serverConfig().recentPackages();
- if( !recent.tqcontains( recent_key ) ) {
+ if( !recent.contains( recent_key ) ) {
recent.prepend( recent_key );
if ( int( recent.count() ) > KBBPrefs::instance()->mRecentPackagesCount ) {
recent.remove( recent.last() );