From 59042563b3af6cc0fff486d40031234a125acf9e Mon Sep 17 00:00:00 2001 From: Jonathan White Date: Sat, 13 May 2023 15:48:06 -0400 Subject: [PATCH] Revert "Support {MODE=VIRTUAL} on macOS" This reverts commit 25fc69dcd40ac9ae678caf63eaba0511d6985621. --- src/autotype/AutoTypeSelectDialog.cpp | 4 ++-- src/autotype/mac/AutoTypeMac.cpp | 4 ---- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/src/autotype/AutoTypeSelectDialog.cpp b/src/autotype/AutoTypeSelectDialog.cpp index 1e767d790..4e31b61d0 100644 --- a/src/autotype/AutoTypeSelectDialog.cpp +++ b/src/autotype/AutoTypeSelectDialog.cpp @@ -326,7 +326,7 @@ void AutoTypeSelectDialog::buildActionMenu() submitAutoTypeMatch(match); }); -#if defined(Q_OS_WIN) || defined(Q_OS_MAC) +#ifdef Q_OS_WIN auto typeVirtualAction = new QAction(icons()->icon("auto-type"), tr("Use Virtual Keyboard"), nullptr); m_actionMenu->insertAction(copyUsernameAction, typeVirtualAction); typeVirtualAction->setShortcut(Qt::CTRL + Qt::Key_4); @@ -342,7 +342,7 @@ void AutoTypeSelectDialog::buildActionMenu() typeUsernameAction->setShortcutVisibleInContextMenu(true); typePasswordAction->setShortcutVisibleInContextMenu(true); typeTotpAction->setShortcutVisibleInContextMenu(true); -#if defined(Q_OS_WIN) || defined(Q_OS_MAC) +#ifdef Q_OS_WIN typeVirtualAction->setShortcutVisibleInContextMenu(true); #endif #endif diff --git a/src/autotype/mac/AutoTypeMac.cpp b/src/autotype/mac/AutoTypeMac.cpp index 05a5d41de..815deeecc 100644 --- a/src/autotype/mac/AutoTypeMac.cpp +++ b/src/autotype/mac/AutoTypeMac.cpp @@ -250,10 +250,6 @@ AutoTypeAction::Result AutoTypeExecutorMac::execType(const AutoTypeKey* action) int ch = action->character.toUpper().toLatin1(); m_platform->sendKey(static_cast(ch), true, action->modifiers); m_platform->sendKey(static_cast(ch), false, action->modifiers); - } else if (mode == Mode::VIRTUAL) { - int ch = action->character.toLatin1(); - m_platform->sendKey(static_cast(ch), true, action->modifiers); - m_platform->sendKey(static_cast(ch), false, action->modifiers); } else { m_platform->sendChar(action->character, true); m_platform->sendChar(action->character, false);