summaryrefslogtreecommitdiffstats
path: root/src/imports/compositor/qwaylandquickcompositorplugin.cpp
diff options
context:
space:
mode:
authorJohan Klokkhammer Helsing <johan.helsing@qt.io>2018-11-14 15:47:00 +0100
committerJohan Helsing <johan.helsing@qt.io>2019-01-24 06:31:16 +0000
commit344e884d93bc35a8011427963f39575e56a5418a (patch)
treeaeececb30cc4e3fa4e42251b17151874faf75009 /src/imports/compositor/qwaylandquickcompositorplugin.cpp
parentf9ba56f24e7d1fcc9d0dc5eabb55335fc64b9a56 (diff)
Add deprecated support for wl_scaler
[ChangeLog][Compositor] Add deprecated support for the deprecated wl_scaler. Some clients are stuck on the unofficial Weston protocol wl_scaler instead of the standardized and stable wp_viewporter. This implements optional support for wl_scaler. This patch has been written to be easily removable in Qt 6, and touches a minimal amount of other code. The implementation can be tested using the new manual test compositor: tests/manual/wlscaler. Weston 1.11.1 has a demo client named weston-resizor, which can be used to test. Note that although newer versions of Weston also have weston-resizor, those versions use wp_viewporter instead of wl_scaler, so you really need 1.11.1 or earlier to test. Fixes: QTBUG-69635 Change-Id: Id572e28044cd764eaf63b1259a92bc589711c39d Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
Diffstat (limited to 'src/imports/compositor/qwaylandquickcompositorplugin.cpp')
-rw-r--r--src/imports/compositor/qwaylandquickcompositorplugin.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/imports/compositor/qwaylandquickcompositorplugin.cpp b/src/imports/compositor/qwaylandquickcompositorplugin.cpp
index 1c576b6a1..d0a38c58c 100644
--- a/src/imports/compositor/qwaylandquickcompositorplugin.cpp
+++ b/src/imports/compositor/qwaylandquickcompositorplugin.cpp
@@ -59,6 +59,7 @@
#include <QtWaylandCompositor/QWaylandResource>
#include <QtWaylandCompositor/QWaylandQtWindowManager>
+#include <QtWaylandCompositor/QWaylandWlScaler>
#include <QtWaylandCompositor/QWaylandWlShell>
#include <QtWaylandCompositor/QWaylandTextInputManager>
#include <QtWaylandCompositor/QWaylandXdgShellV5>
@@ -76,6 +77,7 @@ QT_BEGIN_NAMESPACE
Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CONTAINER_CLASS(QWaylandQuickCompositor)
Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CLASS(QWaylandQtWindowManager)
Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CLASS(QWaylandIviApplication)
+Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CLASS(QWaylandWlScaler)
Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CLASS(QWaylandWlShell)
Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CLASS(QWaylandXdgShellV5)
Q_COMPOSITOR_DECLARE_QUICK_EXTENSION_CLASS(QWaylandXdgShellV6)
@@ -173,6 +175,8 @@ public:
qmlRegisterUncreatableType<QWaylandXdgPopup>(uri, 1, 3, "XdgPopup", QObject::tr("Cannot create instance of XdgShellPopup"));
qmlRegisterType<QWaylandXdgDecorationManagerV1QuickExtension>(uri, 1, 3, "XdgDecorationManagerV1");
+
+ qmlRegisterType<QWaylandWlScalerQuickExtension>(uri, 1, 13, "WlScaler");
}
};
//![class decl]