Avoid mixing different icon types in context menu
This commit is contained in:
parent
2162a9d1e2
commit
3d5286bf26
|
@ -61,9 +61,7 @@ Item {
|
|||
Component.onCompleted: {
|
||||
plasmoid.nativeInterface.initEngine(this)
|
||||
plasmoid.removeAction("configure")
|
||||
plasmoid.setAction(
|
||||
"showWebUI", qsTr("Open Syncthing"),
|
||||
":/icons/hicolor/scalable/status/syncthing-default.svg")
|
||||
plasmoid.setAction("showWebUI", qsTr("Open Syncthing"), "syncthing")
|
||||
plasmoid.setAction("configure", qsTr("Settings"), "configure")
|
||||
plasmoid.setAction("rescanAllDirs", qsTr("Rescan all directories"),
|
||||
"folder-sync")
|
||||
|
|
|
@ -88,6 +88,7 @@ set(REQUIRED_ICONS
|
|||
system-run
|
||||
system-search
|
||||
system-file-manager
|
||||
text-x-generic
|
||||
view-refresh
|
||||
window-close)
|
||||
|
||||
|
|
|
@ -49,8 +49,10 @@ TrayIcon::TrayIcon(const QString &connectionConfig, QObject *parent)
|
|||
|
||||
// set context menu
|
||||
#ifndef SYNCTHINGTRAY_UNIFY_TRAY_MENUS
|
||||
connect(
|
||||
m_contextMenu.addAction(QIcon(QStringLiteral("syncthing.fa")), tr("Open Syncthing")), &QAction::triggered, &widget, &TrayWidget::showWebUi);
|
||||
connect(m_contextMenu.addAction(
|
||||
QIcon::fromTheme(QStringLiteral("syncthing"), QIcon(QStringLiteral(":/icons/hicolor/scalable/status/syncthing-default.svg"))),
|
||||
tr("Open Syncthing")),
|
||||
&QAction::triggered, &widget, &TrayWidget::showWebUi);
|
||||
connect(m_contextMenu.addAction(
|
||||
QIcon::fromTheme(QStringLiteral("preferences-other"), QIcon(QStringLiteral(":/icons/hicolor/scalable/apps/preferences-other.svg"))),
|
||||
tr("Settings")),
|
||||
|
@ -59,7 +61,10 @@ TrayIcon::TrayIcon(const QString &connectionConfig, QObject *parent)
|
|||
QIcon::fromTheme(QStringLiteral("folder-sync"), QIcon(QStringLiteral(":/icons/hicolor/scalable/actions/folder-sync.svg"))),
|
||||
tr("Rescan all")),
|
||||
&QAction::triggered, &widget.connection(), &SyncthingConnection::rescanAllDirs);
|
||||
connect(m_contextMenu.addAction(QIcon(QStringLiteral("file-text.fa")), tr("Log")), &QAction::triggered, &widget, &TrayWidget::showLog);
|
||||
connect(m_contextMenu.addAction(
|
||||
QIcon::fromTheme(QStringLiteral("text-x-generic"), QIcon(QStringLiteral(":/icons/hicolor/scalable/mimetypes/text-x-generic.svg"))),
|
||||
tr("Log")),
|
||||
&QAction::triggered, &widget, &TrayWidget::showLog);
|
||||
m_errorsAction = m_contextMenu.addAction(
|
||||
QIcon::fromTheme(QStringLiteral("emblem-error"), QIcon(QStringLiteral(":/icons/hicolor/scalable/emblems/8/emblem-error.svg"))),
|
||||
tr("Show internal errors"));
|
||||
|
|
Loading…
Reference in New Issue