X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/blobdiff_plain/8f9baef848c3056cd1df772f0774decad509cff3..88a3ee8ac64efefc0bca70aa6560c8ce69f8487b:/src/dolphincontextmenu.cpp diff --git a/src/dolphincontextmenu.cpp b/src/dolphincontextmenu.cpp index e78f3ec1c..5d0bd4adb 100644 --- a/src/dolphincontextmenu.cpp +++ b/src/dolphincontextmenu.cpp @@ -47,6 +47,7 @@ #include #include #include +#include DolphinContextMenu::DolphinContextMenu(DolphinMainWindow* parent, KFileItem* fileInfo, @@ -159,10 +160,10 @@ void DolphinContextMenu::openItemContextMenu() popup->addSeparator(); - // insert 'Bookmark this folder' entry if exactly one item is selected + // insert 'Bookmark This Folder' entry if exactly one item is selected QAction* bookmarkAction = 0; if (m_fileInfo->isDir() && (m_selectedUrls.count() == 1)) { - bookmarkAction = popup->addAction(KIcon("bookmark-folder"), i18n("Bookmark folder")); + bookmarkAction = popup->addAction(KIcon("bookmark-folder"), i18n("Bookmark Folder...")); } // Insert 'Open With...' sub menu @@ -170,7 +171,7 @@ void DolphinContextMenu::openItemContextMenu() const QList openWithActions = insertOpenWithItems(popup, openWithVector); // Insert 'Actions' sub menu - QVector actionsVector; + QVector actionsVector; const QList serviceActions = insertActionItems(popup, actionsVector); popup->addSeparator(); @@ -182,7 +183,7 @@ void DolphinContextMenu::openItemContextMenu() if ((bookmarkAction!= 0) && (activatedAction == bookmarkAction)) { const KUrl selectedUrl(m_fileInfo->url()); - KBookmark bookmark = EditBookmarkDialog::getBookmark(i18n("Add folder as bookmark"), + KBookmark bookmark = EditBookmarkDialog::getBookmark(i18n("Add Folder as Bookmark"), selectedUrl.fileName(), selectedUrl, "bookmark"); @@ -196,7 +197,7 @@ void DolphinContextMenu::openItemContextMenu() else if (serviceActions.contains(activatedAction)) { // one of the 'Actions' items has been selected int id = serviceActions.indexOf(activatedAction); - KDEDesktopMimeType::executeService(m_selectedUrls, actionsVector[id]); + KDesktopFileActions::executeService(m_selectedUrls, actionsVector[id]); } else if (openWithActions.contains(activatedAction)) { // one of the 'Open With' items has been selected @@ -246,10 +247,10 @@ void DolphinContextMenu::openViewportContextMenu() popup->addMenu(viewModeMenu); popup->addSeparator(); - QAction* bookmarkAction = popup->addAction(KIcon("bookmark-folder"), i18n("Bookmark this folder")); + QAction* bookmarkAction = popup->addAction(KIcon("bookmark-folder"), i18n("Bookmark This Folder...")); popup->addSeparator(); - QAction* propertiesAction = popup->addAction(i18n("Properties...")); + QAction* propertiesAction = popup->addAction(i18n("Properties")); QAction* activatedAction = popup->exec(QCursor::pos()); if (activatedAction == propertiesAction) { @@ -257,7 +258,7 @@ void DolphinContextMenu::openViewportContextMenu() } else if (activatedAction == bookmarkAction) { const KUrl& url = m_mainWindow->activeView()->url(); - KBookmark bookmark = EditBookmarkDialog::getBookmark(i18n("Add folder as bookmark"), + KBookmark bookmark = EditBookmarkDialog::getBookmark(i18n("Add Folder as Bookmark"), url.fileName(), url, "bookmark"); @@ -380,7 +381,7 @@ QList DolphinContextMenu::insertOpenWithItems(KMenu* popup, } QList DolphinContextMenu::insertActionItems(KMenu* popup, - QVector& actionsVector) + QVector& actionsVector) { // Parts of the following code have been taken // from the class KonqOperations located in @@ -449,14 +450,14 @@ QList DolphinContextMenu::insertActionItems(KMenu* popup, actionsMenu->addMenu(menu); } - Q3ValueList userServices = - KDEDesktopMimeType::userDefinedServices(*dirIt + *entryIt, true); + Q3ValueList userServices = + KDesktopFileActions::userDefinedServices(*dirIt + *entryIt, true); - Q3ValueList::Iterator serviceIt; + Q3ValueList::Iterator serviceIt; for (serviceIt = userServices.begin(); serviceIt != userServices.end(); ++serviceIt) { - KDEDesktopMimeType::Service service = (*serviceIt); + KDesktopFileActions::Service service = (*serviceIt); if (!service.m_strIcon.isEmpty()) { - QAction* action = menu->addAction(SmallIcon(service.m_strIcon), + QAction* action = menu->addAction(KIcon(service.m_strIcon), service.m_strName); serviceActions << action; }