diff --git a/src/plugins/platforms/windows/qwindowskeymapper.cpp b/src/plugins/platforms/windows/qwindowskeymapper.cpp
index af62936a18..0ed3555b01 100644
--- a/src/plugins/platforms/windows/qwindowskeymapper.cpp
+++ b/src/plugins/platforms/windows/qwindowskeymapper.cpp
@@ -806,6 +806,9 @@ static inline void sendExtendedPressRelease(QWindow *w, int k,
 bool QWindowsKeyMapper::translateKeyEvent(QWindow *widget, HWND hwnd,
                                           const MSG &msg, LRESULT *result)
 {
+   static int n = 0;
+   qDebug() << "\n>" << __FUNCTION__ << '#' << n << msg;
+
     *result = 0;
 
     // Reset layout map when system keyboard layout is changed
@@ -815,8 +818,12 @@ bool QWindowsKeyMapper::translateKeyEvent(QWindow *widget, HWND hwnd,
     }
 
 #if defined(WM_APPCOMMAND)
-    if (msg.message == WM_APPCOMMAND)
-        return translateMultimediaKeyEventInternal(widget, msg);
+    if (msg.message == WM_APPCOMMAND) {
+        bool r= translateMultimediaKeyEventInternal(widget, msg);
+        qDebug() << '<' << __FUNCTION__ << '#' << n << "rets" << r << '\n';
+        n++;
+        return r;
+    }
 #endif
 
     // WM_(IME_)CHAR messages already contain the character in question so there is
@@ -830,15 +837,21 @@ bool QWindowsKeyMapper::translateKeyEvent(QWindow *widget, HWND hwnd,
     if (PeekMessage(&peekedMsg, hwnd, 0, 0, PM_NOREMOVE) && peekedMsg.message == WM_DEADCHAR)
         return true;
 
-    return translateKeyEventInternal(widget, msg, false);
+    bool r= translateKeyEventInternal(widget, msg, false);
+    qDebug() << '<' << __FUNCTION__ << '#' << n << "rets" << r << '\n';
+    n++;
+    return r;
 }
 
 bool QWindowsKeyMapper::translateMultimediaKeyEventInternal(QWindow *window, const MSG &msg)
 {
 #if defined(WM_APPCOMMAND)
     // QTBUG-57198, do not send mouse-synthesized commands as key events in addition
-    if (GET_DEVICE_LPARAM(msg.lParam) == FAPPCOMMAND_MOUSE)
+    qDebug() << '>' << __FUNCTION__ << msg << hex << "FAPPCOMMAND=" << GET_DEVICE_LPARAM(msg.lParam);
+    if (GET_DEVICE_LPARAM(msg.lParam) == FAPPCOMMAND_MOUSE) {
+        qDebug() << __FUNCTION__ << "ret FAPPCOMMAND_MOUSE";
         return false;
+    }
     const int cmd = GET_APPCOMMAND_LPARAM(msg.lParam);
     const int dwKeys = GET_KEYSTATE_LPARAM(msg.lParam);
     int state = 0;
@@ -846,16 +859,19 @@ bool QWindowsKeyMapper::translateMultimediaKeyEventInternal(QWindow *window, con
     state |= (dwKeys & MK_CONTROL ? int(Qt::ControlModifier) : 0);
 
     QWindow *receiver = m_keyGrabber ? m_keyGrabber : window;
-
+    qDebug() << __FUNCTION__ << "cmd=" <<cmd;
     if (cmd < 0 || cmd > 52)
         return false;
 
     const int qtKey = int(CmdTbl[cmd]);
+    qDebug() << __FUNCTION__ << "cmd=" <<cmd << Qt::Key(qtKey);
     sendExtendedPressRelease(receiver, qtKey, Qt::KeyboardModifier(state), 0, 0, 0);
     // QTBUG-43343: Make sure to return false if Qt does not handle the key, otherwise,
     // the keys are not passed to the active media player.
     const QKeySequence sequence(Qt::Modifier(state) + qtKey);
-    return QGuiApplicationPrivate::instance()->shortcutMap.hasShortcutForKeySequence(sequence);
+    bool r = QGuiApplicationPrivate::instance()->shortcutMap.hasShortcutForKeySequence(sequence);
+    qDebug() << '<' << __FUNCTION__ << "rets=" << r;
+    return r;
 #else
     Q_UNREACHABLE();
     return false;
@@ -1163,6 +1179,7 @@ bool QWindowsKeyMapper::translateKeyEventInternal(QWindow *window, const MSG &ms
             }
 #endif // !QT_NO_SHORTCUT
             key_recorder.storeKey(int(msg.wParam), a, state, text);
+            qDebug() << __FUNCTION__ << "down" << msg << Qt::Key(code);
             QWindowSystemInterface::handleExtendedKeyEvent(receiver, QEvent::KeyPress, code,
                                                            modifiers, scancode, quint32(msg.wParam), nModifiers, text, false);
             result =true;
@@ -1204,6 +1221,7 @@ bool QWindowsKeyMapper::translateKeyEventInternal(QWindow *window, const MSG &ms
             // Map SHIFT + Tab to SHIFT + BackTab, QShortcutMap knows about this translation
             if (code == Qt::Key_Tab && (state & Qt::ShiftModifier) == Qt::ShiftModifier)
                 code = Qt::Key_Backtab;
+            qDebug() << __FUNCTION__ << "up" << msg << Qt::Key(code);
             QWindowSystemInterface::handleExtendedKeyEvent(receiver, QEvent::KeyRelease, code,
                                                            Qt::KeyboardModifier(state), scancode, quint32(msg.wParam),
                                                            nModifiers,
