]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/panels/places/placespanel.cpp
Merge branch 'KDE/4.14'
[dolphin.git] / src / panels / places / placespanel.cpp
index d5308eabe1ccf366978d00a2b800cd9f5be60199..720e07ce37e91067b319c108580847b24aaf30af 100644 (file)
@@ -283,8 +283,9 @@ void PlacesPanel::slotItemContextMenuRequested(int index, const QPointF& pos)
             } else if (action == hideAction) {
                 item->setHidden(hideAction->isChecked());
             } else if (action == openInNewTabAction) {
-                const KUrl url = m_model->item(index)->dataValue("url").value<KUrl>();
-                emit placeMiddleClicked(url);
+                // TriggerItem does set up the storage first and then it will
+                // emit the slotItemMiddleClicked signal, because of Qt::MiddleButton.
+                triggerItem(index, Qt::MiddleButton);
             } else if (action == teardownAction) {
                 m_model->requestTeardown(index);
             } else if (action == ejectAction) {
@@ -334,7 +335,7 @@ void PlacesPanel::slotItemDropEvent(int index, QGraphicsSceneDragDropEvent* even
 
     const PlacesItem* destItem = m_model->placesItem(index);
     const PlacesItem::GroupType group = destItem->groupType();
-    if (group == PlacesItem::SearchForType || group == PlacesItem::RecentlyAccessedType) {
+    if (group == PlacesItem::SearchForType || group == PlacesItem::RecentlySavedType) {
         return;
     }