diff --git a/src/autotype/AutoType.cpp b/src/autotype/AutoType.cpp index 2519b9dcb..0d01a8311 100644 --- a/src/autotype/AutoType.cpp +++ b/src/autotype/AutoType.cpp @@ -256,6 +256,13 @@ void AutoType::resetInAutoType() m_inAutoType = false; } +void AutoType::raiseWindow() +{ +#if defined(Q_OS_MAC) + m_plugin->raiseOwnWindow(); +#endif +} + void AutoType::unloadPlugin() { if (m_executor) { diff --git a/src/autotype/AutoType.h b/src/autotype/AutoType.h index 6f4a815f8..e881975ac 100644 --- a/src/autotype/AutoType.h +++ b/src/autotype/AutoType.h @@ -51,6 +51,7 @@ public: public slots: void performGlobalAutoType(const QList& dbList); + void raiseWindow(); signals: void globalShortcutTriggered(); diff --git a/src/gui/DatabaseWidget.cpp b/src/gui/DatabaseWidget.cpp index a610cf506..e5110e30a 100644 --- a/src/gui/DatabaseWidget.cpp +++ b/src/gui/DatabaseWidget.cpp @@ -1400,6 +1400,12 @@ void DatabaseWidget::showUnlockDialog() { m_unlockDatabaseDialog->clearForms(); m_unlockDatabaseDialog->setDBFilename(m_filename); + +#if defined(Q_OS_MAC) + autoType()->raiseWindow(); + Tools::wait(500); +#endif + m_unlockDatabaseDialog->show(); m_unlockDatabaseDialog->activateWindow(); }