diff options
Diffstat (limited to 'src/panels/places')
| -rw-r--r-- | src/panels/places/placesitem.cpp | 2 | ||||
| -rw-r--r-- | src/panels/places/placespanel.cpp | 4 |
2 files changed, 5 insertions, 1 deletions
diff --git a/src/panels/places/placesitem.cpp b/src/panels/places/placesitem.cpp index b32f8204d..4ba1217f0 100644 --- a/src/panels/places/placesitem.cpp +++ b/src/panels/places/placesitem.cpp @@ -316,7 +316,7 @@ void PlacesItem::updateBookmarkForRole(const QByteArray& role) } } else if (role == "url") { m_bookmark.setUrl(url()); - } else if (role == "udi)") { + } else if (role == "udi") { m_bookmark.setMetaDataItem(QStringLiteral("UDI"), udi()); } else if (role == "isSystemItem") { m_bookmark.setMetaDataItem(QStringLiteral("isSystemItem"), isSystemItem() ? QStringLiteral("true") : QStringLiteral("false")); diff --git a/src/panels/places/placespanel.cpp b/src/panels/places/placespanel.cpp index 3c9309435..19a17be08 100644 --- a/src/panels/places/placespanel.cpp +++ b/src/panels/places/placespanel.cpp @@ -25,6 +25,7 @@ #include "dolphin_generalsettings.h" +#include "global.h" #include <KFileItem> #include "dolphindebug.h" #include <KDirNotify> @@ -192,6 +193,7 @@ void PlacesPanel::slotItemContextMenuRequested(int index, const QPointF& pos) } } + QAction* openInNewWindowAction = menu.addAction(QIcon::fromTheme("window-new"), i18nc("@item:inmenu", "Open in New Window")); QAction* openInNewTabAction = menu.addAction(QIcon::fromTheme("tab-new"), i18nc("@item:inmenu", "Open in New Tab")); if (!isDevice && !isTrash) { menu.addSeparator(); @@ -232,6 +234,8 @@ void PlacesPanel::slotItemContextMenuRequested(int index, const QPointF& pos) } else if (action == hideAction) { item->setHidden(hideAction->isChecked()); m_model->saveBookmarks(); + } else if (action == openInNewWindowAction) { + Dolphin::openNewWindow({PlacesItemModel::convertedUrl(m_model->data(index).value("url").toUrl())}, this); } else if (action == openInNewTabAction) { // TriggerItem does set up the storage first and then it will // emit the slotItemMiddleClicked signal, because of Qt::MiddleButton. |
