[oe] [meta-qt5][PATCH] qtwayland: fix initial window property values

Gordan Markuš gordan.markus at pelagicore.com
Tue Apr 11 14:04:33 UTC 2017


This fixes a bug where there is nothing rendered on the
QtWayland surface due to missing window properties.

Signed-off-by: Gordan Markuš <gordan.markus at pelagicore.com>
---
 ...l-window-property-values-being-propagated.patch | 35 ++++++++++++++++++++++
 recipes-qt/qt5/qtwayland_git.bb                    |  5 +++-
 2 files changed, 39 insertions(+), 1 deletion(-)
 create mode 100644 recipes-qt/qt5/qtwayland/0002-Fix-initial-window-property-values-being-propagated.patch

diff --git a/recipes-qt/qt5/qtwayland/0002-Fix-initial-window-property-values-being-propagated.patch b/recipes-qt/qt5/qtwayland/0002-Fix-initial-window-property-values-being-propagated.patch
new file mode 100644
index 0000000..29c9180
--- /dev/null
+++ b/recipes-qt/qt5/qtwayland/0002-Fix-initial-window-property-values-being-propagated.patch
@@ -0,0 +1,35 @@
+From 3d30fd8df9b55449844207295ad3d51cc8bb44b1 Mon Sep 17 00:00:00 2001
+From: Robert Griebl <robert.griebl at pelagicore.com>
+Date: Thu, 15 Dec 2016 17:43:00 +0100
+Subject: [PATCH 2/2] Fix initial window property values being propagated
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+This was broken since the the shell-surface refactoring.
+
+Change-Id: I130b7396e85c570a9d11d609af6b3016e3f706f0
+Reviewed-by: Dominik Holland <dominik.holland at pelagicore.com>
+Reviewed-by: Paul Olav Tvete <paul.tvete at qt.io>
+Signed-off-by: Gordan Markuš <gordan.markus at pelagicore.com>
+---
+ src/client/qwaylandwindow.cpp | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/src/client/qwaylandwindow.cpp b/src/client/qwaylandwindow.cpp
+index c8be9c1..b6f16f0 100644
+--- a/src/client/qwaylandwindow.cpp
++++ b/src/client/qwaylandwindow.cpp
+@@ -176,6 +176,9 @@ void QWaylandWindow::initWindow()
+                 mShellSurface->setAppId(appId);
+             }
+         }
++        // the user may have already set some window properties, so make sure to send them out
++        for (auto it = m_properties.cbegin(); it != m_properties.cend(); ++it)
++            mShellSurface->sendProperty(it.key(), it.value());
+     }
+ 
+     // Enable high-dpi rendering. Scale() returns the screen scale factor and will
+-- 
+2.9.3
+
diff --git a/recipes-qt/qt5/qtwayland_git.bb b/recipes-qt/qt5/qtwayland_git.bb
index d42d80a..bcddb32 100644
--- a/recipes-qt/qt5/qtwayland_git.bb
+++ b/recipes-qt/qt5/qtwayland_git.bb
@@ -44,6 +44,9 @@ EXTRA_QMAKEVARS_CONFIGURE += "${PACKAGECONFIG_CONFARGS}"
 SRCREV = "0e2a950895805457a45abe860bc91a7cc4ba405e"
 
 # From https://bugreports.qt.io/browse/QTBUG-57767
-SRC_URI += "file://0001-fix-build-without-xkbcommon-evdev.patch"
+SRC_URI += " \
+    file://0001-fix-build-without-xkbcommon-evdev.patch \
+    file://0002-Fix-initial-window-property-values-being-propagated.patch \
+"
 
 BBCLASSEXTEND =+ "native nativesdk"
-- 
2.9.3




More information about the Openembedded-devel mailing list