diff --git a/src/plugins/platforms/windows/qwindowscontext.cpp b/src/plugins/platforms/windows/qwindowscontext.cpp index af7713b..0b26b68 100644 --- a/src/plugins/platforms/windows/qwindowscontext.cpp +++ b/src/plugins/platforms/windows/qwindowscontext.cpp @@ -916,6 +916,9 @@ bool QWindowsContext::windowsProc(HWND hwnd, UINT message, return d->m_mouseHandler.translateTouchEvent(platformWindow->window(), hwnd, et, msg, result); #endif case QtWindows::FocusInEvent: // see QWindowsWindow::requestActivateWindow(). + qDebug() << __FUNCTION__ << "FocusInEvent" << platformWindow->window(); + if (platformWindow->window()->objectName().contains(QLatin1String("GL"))) + qDebug("FocusInEvent to GL!!"); case QtWindows::FocusOutEvent: handleFocusEvent(et, platformWindow); return true; diff --git a/src/plugins/platforms/windows/qwindowswindow.cpp b/src/plugins/platforms/windows/qwindowswindow.cpp index db06525..43d69b7 100644 --- a/src/plugins/platforms/windows/qwindowswindow.cpp +++ b/src/plugins/platforms/windows/qwindowswindow.cpp @@ -540,6 +540,8 @@ QWindowsWindowData { typedef QSharedPointer QWindowCreationContextPtr; + qDebug() << __FUNCTION__ << w << w->parent(); + WindowData result; result.flags = flags; @@ -579,7 +581,7 @@ QWindowsWindowData const QWindowCreationContextPtr context(new QWindowCreationContext(w, rect, data.customMargins, style, exStyle)); QWindowsContext::instance()->setWindowCreationContext(context); - qCDebug(lcQpaWindows).nospace() + qDebug().nospace() << "CreateWindowEx: " << w << *this << " class=" <frameWidth << 'x' << context->frameHeight @@ -1239,7 +1241,9 @@ void QWindowsWindow::setParent_sys(const QPlatformWindow *parent) const bool isTopLevel = newParentHWND == 0; setFlag(WithinSetParent); + qDebug() << __FUNCTION__ << '>' << window() << newParentHWND; SetParent(m_data.hwnd, newParentHWND); + qDebug() << __FUNCTION__ << '<'; clearFlag(WithinSetParent); // WS_CHILD/WS_POPUP must be manually set/cleared in addition diff --git a/src/widgets/kernel/qwidget_qpa.cpp b/src/widgets/kernel/qwidget_qpa.cpp index 5ba0a90..afab136 100644 --- a/src/widgets/kernel/qwidget_qpa.cpp +++ b/src/widgets/kernel/qwidget_qpa.cpp @@ -93,6 +93,7 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO { Q_Q(QWidget); + Q_UNUSED(window); Q_UNUSED(initializeWindow); Q_UNUSED(destroyOldWindow); @@ -103,6 +104,8 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO return; // we only care about real toplevels QWindow *win = topData()->window; + qDebug() << __FUNCTION__ << q << "Type" << q->windowType() + << "win=" << win << initializeWindow << destroyOldWindow; // topData() ensures the extra is created but does not ensure 'window' is non-null // in case the extra was already valid. if (!win) { @@ -138,6 +141,9 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO win->setParent(0); } else { win->setTransientParent(0); + qDebug() << __FUNCTION__ << win << "nativeParent=" << nativeParent << + "type: " << nativeParent->windowType() + << nativeParent->windowHandle(); win->setParent(nativeParent->windowHandle()); } }