diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-08-10 06:08:18 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-08-10 06:08:18 +0000 |
commit | 9a3f0aacd44fb866833ebcb852df3cd31475cb33 (patch) | |
tree | 9f699684624f4e78e13e7dd2393a103cc6fa8274 /kcontrol/filetypes | |
parent | 341ad02235b9c85cd31782225181ed475b74eaa3 (diff) | |
download | tdebase-9a3f0aacd44fb866833ebcb852df3cd31475cb33.tar.gz tdebase-9a3f0aacd44fb866833ebcb852df3cd31475cb33.zip |
rename the following methods:
tqfind find
tqreplace replace
tqcontains contains
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kcontrol/filetypes')
-rw-r--r-- | kcontrol/filetypes/filetypesview.cpp | 8 | ||||
-rw-r--r-- | kcontrol/filetypes/typeslistitem.cpp | 22 |
2 files changed, 15 insertions, 15 deletions
diff --git a/kcontrol/filetypes/filetypesview.cpp b/kcontrol/filetypes/filetypesview.cpp index 940d4afa3..45c700fd9 100644 --- a/kcontrol/filetypes/filetypesview.cpp +++ b/kcontrol/filetypes/filetypesview.cpp @@ -174,11 +174,11 @@ void FileTypesView::readFileTypes() TQValueListIterator<KMimeType::Ptr> it2(mimetypes.begin()); for (; it2 != mimetypes.end(); ++it2) { TQString mimetype = (*it2)->name(); - int index = mimetype.tqfind("/"); + int index = mimetype.find("/"); TQString maj = mimetype.left(index); TQString min = mimetype.right(mimetype.length() - index+1); - TQMapIterator<TQString,TypesListItem*> mit = m_majorMap.tqfind( maj ); + TQMapIterator<TQString,TypesListItem*> mit = m_majorMap.find( maj ); if ( mit == m_majorMap.end() ) { groupItem = new TypesListItem( typesLV, maj ); m_majorMap.insert( maj, groupItem ); @@ -196,7 +196,7 @@ void FileTypesView::readFileTypes() void FileTypesView::slotEmbedMajor(const TQString &major, bool &embed) { TypesListItem *groupItem; - TQMapIterator<TQString,TypesListItem*> mit = m_majorMap.tqfind( major ); + TQMapIterator<TQString,TypesListItem*> mit = m_majorMap.find( major ); if ( mit == m_majorMap.end() ) return; @@ -425,7 +425,7 @@ void FileTypesView::slotDatabaseChanged() TQValueList<TypesListItem *>::Iterator it = m_itemsModified.begin(); for( ; it != m_itemsModified.end(); ++it ) { TQString name = (*it)->name(); - if ( removedList.tqfind( name ) == removedList.end() ) // if not deleted meanwhile + if ( removedList.find( name ) == removedList.end() ) // if not deleted meanwhile (*it)->refresh(); } m_itemsModified.clear(); diff --git a/kcontrol/filetypes/typeslistitem.cpp b/kcontrol/filetypes/typeslistitem.cpp index 21061b065..3380f86f9 100644 --- a/kcontrol/filetypes/typeslistitem.cpp +++ b/kcontrol/filetypes/typeslistitem.cpp @@ -92,7 +92,7 @@ void TypesListItem::init(KMimeType::Ptr mimetype) m_bFullInit = false; m_mimetype = mimetype; - int index = mimetype->name().tqfind("/"); + int index = mimetype->name().find("/"); if (index != -1) { m_major = mimetype->name().left(index); m_minor = mimetype->name().right(mimetype->name().length() - @@ -343,18 +343,18 @@ void TypesListItem::sync() continue; // Only those which were added in init() // Look in the correct list... - if ( (isApplication && ! m_appServices.tqcontains( pService->desktopEntryPath() )) - || (!isApplication && !m_embedServices.tqcontains( pService->desktopEntryPath() )) + if ( (isApplication && ! m_appServices.contains( pService->desktopEntryPath() )) + || (!isApplication && !m_embedServices.contains( pService->desktopEntryPath() )) ) { // The service was in m_appServices but has been removed // create a new .desktop file without this mimetype if( s_changedServices == NULL ) deleter.setObject( s_changedServices, new TQMap< TQString, TQStringList > ); - TQStringList mimeTypeList = s_changedServices->tqcontains( pService->desktopEntryPath()) + TQStringList mimeTypeList = s_changedServices->contains( pService->desktopEntryPath()) ? (*s_changedServices)[ pService->desktopEntryPath() ] : pService->serviceTypes(); - if ( mimeTypeList.tqcontains( name() ) ) { + if ( mimeTypeList.contains( name() ) ) { // The mimetype is listed explicitly in the .desktop files, so // just remove it and we're done KConfig *desktop; @@ -370,12 +370,12 @@ void TypesListItem::sync() } desktop->setDesktopGroup(); - mimeTypeList = s_changedServices->tqcontains( pService->desktopEntryPath()) + mimeTypeList = s_changedServices->contains( pService->desktopEntryPath()) ? (*s_changedServices)[ pService->desktopEntryPath() ] : desktop->readListEntry("MimeType", ';'); // Remove entry and the number that might follow. TQStringList::Iterator it; - for(;(it = mimeTypeList.tqfind(name())) != mimeTypeList.end();) + for(;(it = mimeTypeList.find(name())) != mimeTypeList.end();) { it = mimeTypeList.remove(it); if (it != mimeTypeList.end()) @@ -438,7 +438,7 @@ KMimeType::Ptr TypesListItem::findImplicitAssociation(const TQString &desktop) if( s_changedServices == NULL ) deleter.setObject( s_changedServices, new TQMap< TQString, TQStringList > ); - TQStringList mimeTypeList = s_changedServices->tqcontains( s->desktopEntryPath()) + TQStringList mimeTypeList = s_changedServices->contains( s->desktopEntryPath()) ? (*s_changedServices)[ s->desktopEntryPath() ] : s->serviceTypes(); for(TQStringList::ConstIterator it = mimeTypeList.begin(); @@ -477,10 +477,10 @@ void TypesListItem::saveServices( KConfig & profile, TQStringList services, cons // merge new mimetype if( s_changedServices == NULL ) deleter.setObject( s_changedServices, new TQMap< TQString, TQStringList > ); - TQStringList mimeTypeList = s_changedServices->tqcontains( pService->desktopEntryPath()) + TQStringList mimeTypeList = s_changedServices->contains( pService->desktopEntryPath()) ? (*s_changedServices)[ pService->desktopEntryPath() ] : pService->serviceTypes(); - if (!mimeTypeList.tqcontains(name()) && !inheritsMimetype(m_mimetype, mimeTypeList)) + if (!mimeTypeList.contains(name()) && !inheritsMimetype(m_mimetype, mimeTypeList)) { KConfig *desktop; if ( pService->type() == TQString("Service") ) @@ -495,7 +495,7 @@ void TypesListItem::saveServices( KConfig & profile, TQStringList services, cons } desktop->setDesktopGroup(); - mimeTypeList = s_changedServices->tqcontains( pService->desktopEntryPath()) + mimeTypeList = s_changedServices->contains( pService->desktopEntryPath()) ? (*s_changedServices)[ pService->desktopEntryPath() ] : desktop->readListEntry("MimeType", ';'); mimeTypeList.append(name()); |