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 | 10b4cb5e889a28380c1cc4d5e4ebe01a835df6d9 (patch) | |
tree | 9abdedb1613b67baf902467e11607d95e5e86c6c | |
parent | 7b65a26139363081928049b6613475488a057011 (diff) | |
download | dolphin-10b4cb5e889a28380c1cc4d5e4ebe01a835df6d9.tar.gz dolphin-10b4cb5e889a28380c1cc4d5e4ebe01a835df6d9.zip |
rename the following methods:
tqfind find
tqreplace replace
tqcontains contains
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/dolphin@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
-rw-r--r-- | src/Makefile.am | 2 | ||||
-rw-r--r-- | src/dolphin.cpp | 12 | ||||
-rw-r--r-- | src/dolphincontextmenu.cpp | 4 | ||||
-rw-r--r-- | src/dolphindetailsview.cpp | 2 | ||||
-rw-r--r-- | src/dolphiniconsview.cpp | 8 | ||||
-rw-r--r-- | src/dolphinview.cpp | 6 | ||||
-rw-r--r-- | src/infosidebarpage.cpp | 4 | ||||
-rw-r--r-- | src/renamedialog.cpp | 4 | ||||
-rw-r--r-- | src/urlnavigator.cpp | 6 |
9 files changed, 24 insertions, 24 deletions
diff --git a/src/Makefile.am b/src/Makefile.am index 61ae3b9..71eb5e8 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -44,7 +44,7 @@ noinst_HEADERS = bookmarkselector.h bookmarkssettingspage.h \ METASOURCES = AUTO messages: rc.cpp - $(EXTRACTRC) `tqfind . -name \*.ui -o -name \*.rc` > rc.cpp + $(EXTRACTRC) `find . -name \*.ui -o -name \*.rc` > rc.cpp $(XGETTEXT) *.cpp -o $(podir)/d3lphin.pot diff --git a/src/dolphin.cpp b/src/dolphin.cpp index 0fbba54..61f6c11 100644 --- a/src/dolphin.cpp +++ b/src/dolphin.cpp @@ -452,17 +452,17 @@ void Dolphin::createFile() // Get the source path of the template which should be copied. // The source path is part of the URL entry of the desktop file. - const int pos = entry.templatePath.tqfindRev('/'); + const int pos = entry.templatePath.findRev('/'); TQString sourcePath(entry.templatePath.left(pos + 1)); sourcePath += KDesktopFile(entry.templatePath, true).readPathEntry("URL"); TQString name(i18n(entry.name.ascii())); // Most entry names end with "..." (e. g. "HTML File..."), which is ok for // menus but no good choice for a new file name -> remove the dots... - name.tqreplace("...", TQString()); + name.replace("...", TQString()); // add the file extension to the name - name.append(sourcePath.right(sourcePath.length() - sourcePath.tqfindRev('.'))); + name.append(sourcePath.right(sourcePath.length() - sourcePath.findRev('.'))); // Check whether a file with the current name already exists. If yes suggest automatically // a unique file name (e. g. "HTML File" will be replaced by "HTML File_1"). @@ -931,7 +931,7 @@ void Dolphin::openTerminal() void Dolphin::findFile() { - KRun::run("ktqfind", m_activeView->url()); + KRun::run("kfind", m_activeView->url()); } void Dolphin::compareFiles() @@ -1032,7 +1032,7 @@ void Dolphin::addUndoOperation(KIO::Job* job) const KURL::List::Iterator sourceEnd = sourceURLs.end(); while (sourceIt != sourceEnd) { - TQMap<TQString, TQString>::ConstIterator metaIt = metaData.tqfind("trashURL-" + (*sourceIt).path()); + TQMap<TQString, TQString>::ConstIterator metaIt = metaData.find("trashURL-" + (*sourceIt).path()); if (metaIt != metaData.end()) { newSourceURLs.append(KURL(metaIt.data())); } @@ -1330,7 +1330,7 @@ void Dolphin::setupActions() KAction* findFileAction = new KAction(i18n("Find File..."), "Ctrl+F", TQT_TQOBJECT(this), TQT_SLOT(findFile()), actionCollection(), "find_file"); - findFileAction->setIcon("filetqfind"); + findFileAction->setIcon("filefind"); new KToggleAction(i18n("Show Filter Bar"), "filter", "/", TQT_TQOBJECT(this), TQT_SLOT(showFilterBar()), diff --git a/src/dolphincontextmenu.cpp b/src/dolphincontextmenu.cpp index be433ea..3c85b71 100644 --- a/src/dolphincontextmenu.cpp +++ b/src/dolphincontextmenu.cpp @@ -401,11 +401,11 @@ void DolphinContextMenu::insertActionItems(KPopupMenu* popup, insert = true; while (insert && ((item = mimeIt.current()) != 0)) { const TQString mimeType((*mimeIt)->mimetype()); - const TQString mimeGroup(mimeType.left(mimeType.tqfind('/'))); + const TQString mimeGroup(mimeType.left(mimeType.find('/'))); insert = (*it == mimeType) || ((*it).right(1) == "*") && - ((*it).left((*it).tqfind('/')) == mimeGroup); + ((*it).left((*it).find('/')) == mimeGroup); ++mimeIt; } } diff --git a/src/dolphindetailsview.cpp b/src/dolphindetailsview.cpp index df23295..8c68454 100644 --- a/src/dolphindetailsview.cpp +++ b/src/dolphindetailsview.cpp @@ -578,7 +578,7 @@ void DolphinDetailsView::slotAutoScroll() const bool scroll = !TQRect(scrollMargin, scrollMargin, viewport()->width() - 2 * scrollMargin, - viewport()->height() - 2 * scrollMargin).tqcontains(pos); + viewport()->height() - 2 * scrollMargin).contains(pos); if (scroll) { if (m_scrollTimer == 0) { m_scrollTimer = new TQTimer( this ); diff --git a/src/dolphiniconsview.cpp b/src/dolphiniconsview.cpp index 436d3b6..5c6f87a 100644 --- a/src/dolphiniconsview.cpp +++ b/src/dolphiniconsview.cpp @@ -232,8 +232,8 @@ void DolphinIconsView::arrangeItemsInGrid( bool updated ) TQString mimetype; while (item != 0) { mimetype = item->fileInfo()->mimetype(); - const bool fixSize = mimetype.tqcontains("text") || - mimetype.tqcontains("application/x-"); + const bool fixSize = mimetype.contains("text") || + mimetype.contains("application/x-"); if (fixSize) { item->setPixmapSize(TQSize(m_previewIconSize, m_previewIconSize)); } @@ -360,7 +360,7 @@ void DolphinIconsView::contentsDragMoveEvent(TQDragMoveEvent* event) // If a dragging is done above a directory, show the icon as 'active' for // a visual feedback - KFileIconViewItem* item = static_cast<KFileIconViewItem*>(tqfindItem(contentsToViewport(event->pos()))); + KFileIconViewItem* item = static_cast<KFileIconViewItem*>(findItem(contentsToViewport(event->pos()))); bool showActive = false; if (item != 0) { @@ -387,7 +387,7 @@ void DolphinIconsView::contentsDropEvent(TQDropEvent* event) return; } - KFileIconViewItem* item = static_cast<KFileIconViewItem*>(tqfindItem(contentsToViewport(event->pos()))); + KFileIconViewItem* item = static_cast<KFileIconViewItem*>(findItem(contentsToViewport(event->pos()))); const bool accept = KURLDrag::canDecode(event) && (event->action() == TQDropEvent::Copy || event->action() == TQDropEvent::Move || diff --git a/src/dolphinview.cpp b/src/dolphinview.cpp index 3c476bf..845cc32 100644 --- a/src/dolphinview.cpp +++ b/src/dolphinview.cpp @@ -224,7 +224,7 @@ void DolphinView::renameSelectedItems() UndoManager& undoMan = UndoManager::instance(); undoMan.beginMacro(); - assert(newName.tqcontains('#')); + assert(newName.contains('#')); const int urlsCount = urls.count(); ProgressIndicator* progressIndicator = @@ -233,12 +233,12 @@ void DolphinView::renameSelectedItems() urlsCount); // iterate through all selected items and rename them... - const int replaceIndex = newName.tqfind('#'); + const int replaceIndex = newName.find('#'); assert(replaceIndex >= 0); for (int i = 0; i < urlsCount; ++i) { const KURL& source = urls[i]; TQString name(newName); - name.tqreplace(replaceIndex, 1, renameIndexPresentation(i + 1, urlsCount)); + name.replace(replaceIndex, 1, renameIndexPresentation(i + 1, urlsCount)); if (source.fileName() != name) { KURL dest(source.upURL()); diff --git a/src/infosidebarpage.cpp b/src/infosidebarpage.cpp index b777ac1..5d4fbbb 100644 --- a/src/infosidebarpage.cpp +++ b/src/infosidebarpage.cpp @@ -471,11 +471,11 @@ void InfoSidebarPage::insertActions() insert = true; while (insert && ((item = mimeIt.current()) != 0)) { const TQString mimeType((*mimeIt)->mimetype()); - const TQString mimeGroup(mimeType.left(mimeType.tqfind('/'))); + const TQString mimeGroup(mimeType.left(mimeType.find('/'))); insert = (*it == mimeType) || ((*it).right(1) == "*") && - ((*it).left((*it).tqfind('/')) == mimeGroup); + ((*it).left((*it).find('/')) == mimeGroup); ++mimeIt; } } diff --git a/src/renamedialog.cpp b/src/renamedialog.cpp index 5724112..abd3057 100644 --- a/src/renamedialog.cpp +++ b/src/renamedialog.cpp @@ -49,7 +49,7 @@ RenameDialog::RenameDialog(const KURL::List& items) : // case, add this postfix to the name suggestion. postfix.insert(0, '.'); for (int i = 1; i < itemCount; ++i) { - if (!items[i].prettyURL().tqcontains(postfix)) { + if (!items[i].prettyURL().contains(postfix)) { // at least one item does not have the same postfix postfix.truncate(0); break; @@ -79,7 +79,7 @@ RenameDialog::~RenameDialog() void RenameDialog::slotOk() { m_newName = m_lineEdit->text(); - if (m_newName.tqcontains('#') != 1) { + if (m_newName.contains('#') != 1) { m_newName.truncate(0); } diff --git a/src/urlnavigator.cpp b/src/urlnavigator.cpp index 3f01e1b..58de6b0 100644 --- a/src/urlnavigator.cpp +++ b/src/urlnavigator.cpp @@ -179,7 +179,7 @@ void URLNavigator::setURL(const KURL& url) if (urlStr.at(0) == '~') { - // tqreplace '~' by the home directory + // replace '~' by the home directory urlStr.remove(0, 1); urlStr.insert(0, TQDir::home().path()); } @@ -451,8 +451,8 @@ void URLNavigator::updateContent() // path. E. g. "fish://[email protected]/var/lib" writes // "fish://[email protected]" to 'bookmarkPath', which leads to the // navigation indication 'Custom Path > var > lib". - int idx = path.tqfind(TQString("//")); - idx = path.tqfind("/", (idx < 0) ? 0 : idx + 2); + int idx = path.find(TQString("//")); + idx = path.find("/", (idx < 0) ? 0 : idx + 2); bookmarkPath = (idx < 0) ? path : path.left(idx); } else { |