X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/blobdiff_plain/8b306b67bfcfec3bb042e4fcd6c89f2daa25cc08..889a574fcdde7d378cdcec75ffc5972b39efbf55:/src/panels/folders/treeviewcontextmenu.cpp diff --git a/src/panels/folders/treeviewcontextmenu.cpp b/src/panels/folders/treeviewcontextmenu.cpp index 13a5c40f1..e45fcd67e 100644 --- a/src/panels/folders/treeviewcontextmenu.cpp +++ b/src/panels/folders/treeviewcontextmenu.cpp @@ -29,7 +29,7 @@ #include #include #include -#include +#include #include #include #include @@ -42,6 +42,7 @@ #include #include #include +#include TreeViewContextMenu::TreeViewContextMenu(FoldersPanel* parent, const KFileItem& fileInfo) : @@ -148,7 +149,7 @@ void TreeViewContextMenu::open() } } - QWeakPointer popupPtr = popup; + QPointer popupPtr = popup; popup->exec(QCursor::pos()); if (popupPtr.data()) { popupPtr.data()->deleteLater(); @@ -193,7 +194,7 @@ void TreeViewContextMenu::rename() void TreeViewContextMenu::moveToTrash() { - const QList list {QList() << m_fileItem.url()}; + const QList list{m_fileItem.url()}; KIO::JobUiDelegate uiDelegate; uiDelegate.setWindow(m_parent); if (uiDelegate.askDeleteConfirmation(list, KIO::JobUiDelegate::Trash, KIO::JobUiDelegate::DefaultConfirmation)) { @@ -206,7 +207,7 @@ void TreeViewContextMenu::moveToTrash() void TreeViewContextMenu::deleteItem() { - const QList list {QList() << m_fileItem.url()}; + const QList list{m_fileItem.url()}; KIO::JobUiDelegate uiDelegate; uiDelegate.setWindow(m_parent); if (uiDelegate.askDeleteConfirmation(list, KIO::JobUiDelegate::Delete, KIO::JobUiDelegate::DefaultConfirmation)) {