mirror of
https://invent.kde.org/system/dolphin
synced 2024-09-12 12:54:29 +00:00
KonqOperations: KIO::pasteMimeData -> KIO::paste, update signal and simplify dolphin accordingly.
This commit is contained in:
parent
3e14a97a0f
commit
30175dcbde
|
@ -1050,9 +1050,7 @@ void DolphinView::slotItemDropEvent(int index, QGraphicsSceneDragDropEvent* even
|
||||||
// Mark the dropped urls as selected.
|
// Mark the dropped urls as selected.
|
||||||
m_clearSelectionBeforeSelectingNewItems = true;
|
m_clearSelectionBeforeSelectingNewItems = true;
|
||||||
m_markFirstNewlySelectedItemAsCurrent = true;
|
m_markFirstNewlySelectedItemAsCurrent = true;
|
||||||
connect(job, static_cast<void(KonqOperations::*)(const QList<QUrl>&)>(&KonqOperations::aboutToCreate), this, &DolphinView::slotAboutToCreate);
|
connect(job, &KonqOperations::itemCreated, this, &DolphinView::slotItemCreated);
|
||||||
// TODO
|
|
||||||
//connect(job, &KIO::InteractiveDropJob::itemCreated, this, &DolphinView::slotItemCreated);
|
|
||||||
//connect(job, &KIO::InteractiveDropJob::result, this, &DolphinView::slotPasteJobResult);
|
//connect(job, &KIO::InteractiveDropJob::result, this, &DolphinView::slotPasteJobResult);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1089,17 +1087,6 @@ void DolphinView::slotMouseButtonPressed(int itemIndex, Qt::MouseButtons buttons
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void DolphinView::slotAboutToCreate(const QList<QUrl>& urls)
|
|
||||||
{
|
|
||||||
if (!urls.isEmpty()) {
|
|
||||||
if (m_markFirstNewlySelectedItemAsCurrent) {
|
|
||||||
markUrlAsCurrent(urls.first());
|
|
||||||
m_markFirstNewlySelectedItemAsCurrent = false;
|
|
||||||
}
|
|
||||||
m_selectedUrls << KDirModel::simplifiedUrlList(urls);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
void DolphinView::slotItemCreated(const QUrl& url)
|
void DolphinView::slotItemCreated(const QUrl& url)
|
||||||
{
|
{
|
||||||
if (m_markFirstNewlySelectedItemAsCurrent) {
|
if (m_markFirstNewlySelectedItemAsCurrent) {
|
||||||
|
|
|
@ -577,7 +577,6 @@ private slots:
|
||||||
* Is called after all pasted or dropped items have been copied to destination.
|
* Is called after all pasted or dropped items have been copied to destination.
|
||||||
*/
|
*/
|
||||||
void slotPasteJobResult(KJob *job);
|
void slotPasteJobResult(KJob *job);
|
||||||
void slotAboutToCreate(const QList<QUrl> &urls);
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Emits the signal \a selectionChanged() with a small delay. This is
|
* Emits the signal \a selectionChanged() with a small delay. This is
|
||||||
|
|
Loading…
Reference in a new issue