diff --git a/src/qt/guiutil.cpp b/src/qt/guiutil.cpp index ee841ce626b..a5a5a7a5cd3 100644 --- a/src/qt/guiutil.cpp +++ b/src/qt/guiutil.cpp @@ -411,14 +411,22 @@ void bringToFront(QWidget* w) #endif if (w) { - // activateWindow() (sometimes) helps with keyboard focus on Windows - if (w->isMinimized()) { - w->showNormal(); - } else { + if (QGuiApplication::platformName() == "wayland") { + auto flags = w->windowFlags(); + w->setWindowFlags(flags|Qt::WindowStaysOnTopHint); + w->show(); + w->setWindowFlags(flags); w->show(); + } else { + // activateWindow() (sometimes) helps with keyboard focus on Windows + if (w->isMinimized()) { + w->showNormal(); + } else { + w->show(); + } + w->activateWindow(); + w->raise(); } - w->activateWindow(); - w->raise(); } }