diff options
author | Andrea Diamantini <adjam7@gmail.com> | 2013-08-01 19:39:04 +0200 |
---|---|---|
committer | Andrea Diamantini <adjam7@gmail.com> | 2013-08-01 19:39:04 +0200 |
commit | 8067811130022f2024558bda7be4a6760d2b9189 (patch) | |
tree | 4e119b283b5153cbbeedb44ceb101c1862e3d523 | |
parent | Add contextual action when in fullscreen to easily exit (diff) | |
download | rekonq-8067811130022f2024558bda7be4a6760d2b9189.tar.xz |
Contextual menu work
Group inspect action alone as requested and reorganized action as
proposed. Now we have
--- OPEN ACTION ---
open here
open there
open everywhere
--- SAVE ---
save link as..
--- LINK RELATED
copy link
bookmark link
share link
----
inspect
.
"Save link" is the text chosen in KDE, webkit, chrom* && firefox. I
don't want to change it.
BUG: 322987
BUG: 322988
-rw-r--r-- | src/webtab/webview.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/webtab/webview.cpp b/src/webtab/webview.cpp index 3e7390e6..6b8416fe 100644 --- a/src/webtab/webview.cpp +++ b/src/webtab/webview.cpp @@ -355,7 +355,7 @@ void WebView::contextMenuEvent(QContextMenuEvent *event) menu.addSeparator(); - //Frame + // Frame KActionMenu *frameMenu = new KActionMenu(i18n("Current Frame"), &menu); frameMenu->addAction(pageAction(KWebPage::OpenFrameInNewWindow)); @@ -394,7 +394,6 @@ void WebView::contextMenuEvent(QContextMenuEvent *event) sendByMailAction->setData(m_contextMenuHitResult.linkUrl()); sendByMailAction->setText(i18n("Share link")); - a = new KAction(KIcon("tab-new"), i18n("Open in New &Tab"), &menu); a->setData(m_contextMenuHitResult.linkUrl()); connect(a, SIGNAL(triggered(bool)), this, SLOT(openLinkInNewTab())); @@ -431,7 +430,6 @@ void WebView::contextMenuEvent(QContextMenuEvent *event) a->setText(i18n("Save Link")); menu.addAction(a); - menu.addAction(pageAction(KWebPage::CopyLinkToClipboard)); } // IMAGE ACTIONS ------------------------------------------------------------------ @@ -564,7 +562,9 @@ void WebView::contextMenuEvent(QContextMenuEvent *event) // DEFAULT ACTIONs (on the bottom) ------------------------------------------------ menu.addSeparator(); if (resultHit & WebView::LinkSelection) - { + { + menu.addAction(pageAction(KWebPage::CopyLinkToClipboard)); + a = new KAction(KIcon("bookmark-new"), i18n("&Bookmark link"), &menu); a->setData(m_contextMenuHitResult.linkUrl()); connect(a, SIGNAL(triggered(bool)), this, SLOT(bookmarkLink())); @@ -580,6 +580,7 @@ void WebView::contextMenuEvent(QContextMenuEvent *event) } menu.addAction(sendByMailAction); + menu.addSeparator(); if (webwin) menu.addAction(webwin->actionByName("web_inspector")); |