From 61c49611fc2e999e2f4467b2ebdb0d188de578e6 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Thu, 26 Sep 2013 16:48:09 +0200 Subject: Windows: Use PostMessage for clipboard notifications for debugged apps. Task-number: QTBUG-33492 Change-Id: I68af5f8ad767c55c95f758259cbb5d8a8080e70e Reviewed-by: Joerg Bornemann --- src/plugins/platforms/windows/qwindowsclipboard.cpp | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'src/plugins/platforms/windows') diff --git a/src/plugins/platforms/windows/qwindowsclipboard.cpp b/src/plugins/platforms/windows/qwindowsclipboard.cpp index cf6cb199c7..51e0d0e803 100644 --- a/src/plugins/platforms/windows/qwindowsclipboard.cpp +++ b/src/plugins/platforms/windows/qwindowsclipboard.cpp @@ -203,13 +203,12 @@ void QWindowsClipboard::propagateClipboardMessage(UINT message, WPARAM wParam, L qWarning("%s: Cowardly refusing to send clipboard message to hung application...", Q_FUNC_INFO); return; } - // Also refuse if the process is being debugged, specifically, if it is + // Do not block if the process is being debugged, specifically, if it is // displaying a runtime assert, which is not caught by isHungAppWindow(). - if (isProcessBeingDebugged(m_nextClipboardViewer)) { - qWarning("%s: Cowardly refusing to send clipboard message to application under debugger...", Q_FUNC_INFO); - return; - } - SendMessage(m_nextClipboardViewer, message, wParam, lParam); + if (isProcessBeingDebugged(m_nextClipboardViewer)) + PostMessage(m_nextClipboardViewer, message, wParam, lParam); + else + SendMessage(m_nextClipboardViewer, message, wParam, lParam); } /*! -- cgit v1.2.3