diff options
author | Roger Maclean <rmaclean@qnx.com> | 2014-01-07 14:10:32 -0500 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-01-17 14:32:36 +0100 |
commit | 6e836271fd851c31cb7408c183aa3fd193d1a835 (patch) | |
tree | 1c56b6a26ee9135c33b684c53f7169f6ebc9ab26 /src/plugins/platforms/qnx/qqnxscreen.h | |
parent | 5c3faa52d7aaab64d1aa6c3800466292a3c3ce18 (diff) |
QNX: Make window groups work reliably
Window group related code worked previously only for the 'root'
window and other windows that had no parents (which then joined
the window group of the root).
Introduced a new function joinGroup that makes the group related
calls, this can both join and leave groups.
Default group joining is performed in setVisible now rather than
setScreen. The advantage of setVisible is that one can rely on it
getting called at some point but it is also possible to create and
interact with a QQnxWindow before it is called. This allows
the default group handling to be overridden via the native
interface. If the group is set (or explicitly not set) then the
default handling is not done.
joinGroup is also called from setParent so that if the parent window
is changed the window joins the parent group.
Change-Id: I03e3801ecb4e4cf901c02e45f00472a87692c2ec
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
Diffstat (limited to 'src/plugins/platforms/qnx/qqnxscreen.h')
-rw-r--r-- | src/plugins/platforms/qnx/qqnxscreen.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/platforms/qnx/qqnxscreen.h b/src/plugins/platforms/qnx/qqnxscreen.h index 61c47e6c72..d39a210d4b 100644 --- a/src/plugins/platforms/qnx/qqnxscreen.h +++ b/src/plugins/platforms/qnx/qqnxscreen.h @@ -80,7 +80,7 @@ public: int nativeFormat() const { return (depth() == 32) ? SCREEN_FORMAT_RGBA8888 : SCREEN_FORMAT_RGB565; } screen_display_t nativeDisplay() const { return m_display; } screen_context_t nativeContext() const { return m_screenContext; } - const char *windowGroupName() const { return rootWindow()->groupName().constData(); } + const char *windowGroupName() const { return m_rootWindow ? m_rootWindow->groupName().constData() : 0; } QQnxWindow *findWindow(screen_window_t windowHandle); |