From 532d7e281652ef26be33451ca6e1b830b912dadc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mladen=20Pejakovi=C4=87?= Date: Sun, 22 Jan 2012 01:24:35 +0100 Subject: [PATCH] Icons and send via mail menu entry in Audio/Video elements --- src/webview/webview.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/webview/webview.cpp b/src/webview/webview.cpp index 5f22994aa..d2838aa99 100644 --- a/src/webview/webview.cpp +++ b/src/webview/webview.cpp @@ -380,11 +380,12 @@ QMenu *WebView::createMediaContextMenu(const QWebHitTestResult &hitTest) bool muted = m_mediaElement.evaluateJavaScript("this.muted").toBool(); QUrl videoUrl = m_mediaElement.evaluateJavaScript("this.currentSrc").toUrl(); - menu->addAction(paused ? tr("Un&pause") : tr("&Pause"), this, SLOT(pauseMedia())); - menu->addAction(muted ? tr("Un&mute") : tr("&Mute"), this, SLOT(muteMedia())); + menu->addAction(paused ? tr("&Play") : tr("&Pause"), this, SLOT(pauseMedia()))->setIcon(QIcon::fromTheme(paused ? "media-playback-start" : "media-playback-pause")); + menu->addAction(muted ? tr("Un&mute") : tr("&Mute"), this, SLOT(muteMedia()))->setIcon(QIcon::fromTheme(muted ? "audio-volume-high" : "audio-volume-high")); menu->addSeparator(); - menu->addAction(tr("Copy Media &Address"), this, SLOT(copyLinkToClipboard()))->setData(videoUrl); - menu->addAction(tr("&Download Media To Disk"), this, SLOT(downloadLinkToDisk()))->setData(videoUrl); + menu->addAction(QIcon::fromTheme("edit-copy"), tr("&Copy Media Address"), this, SLOT(copyLinkToClipboard()))->setData(videoUrl); + menu->addAction(QIcon::fromTheme("mail-message-new"), tr("&Send Media Address"), this, SLOT(sendLinkByMail()))->setData(videoUrl); + menu->addAction(QIcon::fromTheme("download"), tr("&Download Media To Disk"), this, SLOT(downloadLinkToDisk()))->setData(videoUrl); return menu; }