summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/mainwindow.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index 69f90ce4..d0ed5029 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -6491,10 +6491,14 @@ void MainWindow::dropEvent(QDropEvent *event)
void MainWindow::keyReleaseEvent(QKeyEvent *event)
{
- // if the menubar is hidden, pressing Alt will make it visible
- if (event->key() == Qt::Key_Alt) {
- if (!ui->menuBar->isVisible()) {
- ui->menuBar->show();
+ // if the ui is locked, ignore the ALT key event
+ // alt-tabbing out of a game triggers this
+ if (!UILocker::instance().locked()) {
+ // if the menubar is hidden, pressing Alt will make it visible
+ if (event->key() == Qt::Key_Alt) {
+ if (!ui->menuBar->isVisible()) {
+ ui->menuBar->show();
+ }
}
}