Skip to content
Browse files

Fix application shortcuts not working in minimal mode.

Hiding elements of the UI like the icon toolbar disabled the
actions in it. As we want the shortcuts of the actions always
available we need to work around this behavior.

This patch adds all actions found in the object tree of the main-window
directly to the main window. As we don't use the auto-generated
context menu for that there shouldn't be any side-effects.

Another possible way would be to manually create QShortcuts and use
those instead. This would have much bigger code impact though.
  • Loading branch information...
hacst committed Sep 21, 2013
1 parent 39697c7 commit 5b9e899c5865a9270e26197017d33411f9888039
Showing with 4 additions and 4 deletions.
  1. +4 −4 src/mumble/MainWindow.cpp
@@ -167,10 +167,10 @@ MainWindow::MainWindow(QWidget *p) : QMainWindow(p) {
connect(qmChannel, SIGNAL(aboutToShow()), this, SLOT(qmChannel_aboutToShow()));
connect(qteChat, SIGNAL(entered(QString)), this, SLOT(sendChatbarMessage(QString)));

// Fix context of all actions.
QList<QAction *> qla = findChildren<QAction *>();
foreach(QAction *a, qla)

// Explicitely add actions to mainwindow so their shortcuts are available
// if only the main window is visible (e.g. minimal mode)


0 comments on commit 5b9e899

Please sign in to comment.
You can’t perform that action at this time.