diff options
Diffstat (limited to 'src/widgets')
-rw-r--r-- | src/widgets/mainwindowmenubar.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/widgets/mainwindowmenubar.cpp b/src/widgets/mainwindowmenubar.cpp index 0770a8d..cd27a98 100644 --- a/src/widgets/mainwindowmenubar.cpp +++ b/src/widgets/mainwindowmenubar.cpp @@ -24,6 +24,8 @@ #include <QInputDialog> #include "forms/profilesdialog.h" +#include "interfaces.h" + MainWindowMenuBar::MainWindowMenuBar(MainWindow *parent) : QMenuBar(parent) { @@ -52,6 +54,17 @@ MainWindowMenuBar::MainWindowMenuBar(MainWindow *parent) : toolsMenu->addSeparator(); toolsMenu->addAction(tr("Filter"), qApp->blocklists(), SLOT(show()), QKeySequence::fromString(sSettings->value("blocker.shortcut").toString())); + if(qApp->plugin()) { + GuiInterface *gui = qobject_cast<GuiInterface *>(qApp->plugin()); + if(gui) { + toolsMenu->addAction(gui->action()); + } else { + qDebug("Plugin doesn't gui"); + } + } else { + qDebug("No plugin!"); + } + // Profile menu QMenu *profileMenu = new QMenu(tr("Profile"), this); addMenu(profileMenu); |