summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarius Vlad <marius.vlad@collabora.com>2020-08-04 01:06:47 +0300
committerMarius Vlad <marius.vlad@collabora.com>2020-08-04 13:01:12 +0300
commit979d7ff06bf54a50ccac0a4c07b3c74fad132e52 (patch)
treeed60300f629225fc4c3e62ad57ff2db487f3f3e5
parent4ae6b4d3c215f007ec5acc391b795bd447421d35 (diff)
qtwayland_%.bbappend: Do not enable by default resize after swap envsandbox/mvlad/fix-invalid-resize
variable In our use-cases applications do not specify a size for the windows, leaving qtwayland itself to create an initial size for the surface (a 500 by 500 size). The compositor will send a configure event back to the application with the available/actual geometry area, resulting in resize performed by the application. This, in tandem with the fact that we tweaked qtwayland to perform the resize (due to SPEC-3334) after a buffer swap results in a short flicker -- the application does an initial commit with that initial size but with no background or any information attached to it. The environmental variable tunes the repainting mechanism in qtwayland affecting the way the resize is performed and was added because for multiple or split surfaces destroying one of them will not cause a scale back to the original area. We therefore disable by default that environment variable and leave it to the applications to enable it at start-up, if they still want to use split type of surfaces. Added a rather big comment about why that might necessary giving some clues and some mention that qtwayland doesn't make a distinction of the value of the environmental variable itself. Bug-AGL: SPEC-3522 Signed-off-by: Marius Vlad <marius.vlad@collabora.com> Change-Id: I63a5a34a625169e0af3e92c16f2aba7b2e750ec2
-rw-r--r--meta-agl-profile-graphical-qt5/recipes-qt/qt5/qtwayland_%.bbappend9
1 files changed, 8 insertions, 1 deletions
diff --git a/meta-agl-profile-graphical-qt5/recipes-qt/qt5/qtwayland_%.bbappend b/meta-agl-profile-graphical-qt5/recipes-qt/qt5/qtwayland_%.bbappend
index 85ebc29..cdbb0c3 100644
--- a/meta-agl-profile-graphical-qt5/recipes-qt/qt5/qtwayland_%.bbappend
+++ b/meta-agl-profile-graphical-qt5/recipes-qt/qt5/qtwayland_%.bbappend
@@ -31,5 +31,12 @@ QT_SHELL_FILE = "${AFM_CONF_DIR}/qt-shell"
do_install_append_class-target() {
mkdir -p ${AFM_CONF_DIR}
echo "QT_WAYLAND_SHELL_INTEGRATION=${AGL_DEFAULT_WM_SHELL}" > ${QT_SHELL_FILE}
- echo "QT_WAYLAND_RESIZE_AFTER_SWAP=1" >> ${QT_SHELL_FILE}
+ echo -ne "# The following might be necessary to be enabled when multiple/split surfaces\n"\
+ "# are created. Without this enabled, QtWayland will sometimes maintain the same/old\n"\
+ "# size even if the split surface is destroyed. We keep it disabled by default as it\n"\
+ "# causes an additional repaint of the surface until the compositor sends a configure\n"\
+ "# event to scale the window to the actual area. Typical windows will default to a initial\n"\
+ "# size when starting-up without an explicit size specified. Note that QtWayland will only test\n"\
+ "# the presence of the environment variable so it will be enabled even if set to 0\n" >> ${QT_SHELL_FILE}
+ echo "#QT_WAYLAND_RESIZE_AFTER_SWAP=1" >> ${QT_SHELL_FILE}
}