]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/views/dolphinview.cpp
DolphinView: rename copySelectedItems to copySelectedItemsToClipboard
[dolphin.git] / src / views / dolphinview.cpp
index f0dc17837a5ddcad2bb3a18a50aa5bb19382fb1e..c98929ead97dbfc545bb6bf783d339f7317c1604 100644 (file)
@@ -364,7 +364,7 @@ void DolphinView::markUrlAsCurrent(const QUrl &url)
     m_scrollToCurrentItem = true;
 }
 
-void DolphinView::selectItems(const QRegExp& pattern, bool enabled)
+void DolphinView::selectItems(const QRegularExpression &regexp, bool enabled)
 {
     const KItemListSelectionManager::SelectionMode mode = enabled
                                                         ? KItemListSelectionManager::Select
@@ -373,7 +373,7 @@ void DolphinView::selectItems(const QRegExp& pattern, bool enabled)
 
     for (int index = 0; index < m_model->count(); index++) {
         const KFileItem item = m_model->fileItem(index);
-        if (pattern.exactMatch(item.text())) {
+        if (regexp.match(item.text()).hasMatch()) {
             // An alternative approach would be to store the matching items in a KItemSet and
             // select them in one go after the loop, but we'd need a new function
             // KItemListSelectionManager::setSelected(KItemSet, SelectionMode mode)
@@ -686,7 +686,7 @@ void DolphinView::cutSelectedItems()
     QApplication::clipboard()->setMimeData(mimeData);
 }
 
-void DolphinView::copySelectedItems()
+void DolphinView::copySelectedItemsToClipboard()
 {
     QMimeData* mimeData = selectionMimeData();
     QApplication::clipboard()->setMimeData(mimeData);