summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
Diffstat (limited to 'examples')
-rw-r--r--examples/wayland/hwlayer-compositor/main.qml5
-rw-r--r--examples/wayland/minimal-qml/main.qml8
-rw-r--r--examples/wayland/multi-screen/qml/main.qml6
-rw-r--r--examples/wayland/overview-compositor/main.qml4
-rw-r--r--examples/wayland/pure-qml/qml/main.qml7
-rw-r--r--examples/wayland/spanning-screens/main.qml4
6 files changed, 24 insertions, 10 deletions
diff --git a/examples/wayland/hwlayer-compositor/main.qml b/examples/wayland/hwlayer-compositor/main.qml
index 2f6a5f0de..b4f088c9d 100644
--- a/examples/wayland/hwlayer-compositor/main.qml
+++ b/examples/wayland/hwlayer-compositor/main.qml
@@ -51,7 +51,7 @@
import QtQuick 2.6
import QtQuick.Window 2.2
import QtQuick.Controls 2.2
-import QtWayland.Compositor 1.2
+import QtWayland.Compositor 1.3
WaylandCompositor {
WaylandOutput {
@@ -155,6 +155,7 @@ WaylandCompositor {
function addShellSurface(shellSurface) {
shellSurfaces.append({shSurface: shellSurface, animatePosition: false, animateOpacity: false, level: 0});
}
- WlShell { onWlShellSurfaceCreated: addShellSurface(shellSurface) }
+ XdgShell { onToplevelCreated: addShellSurface(xdgSurface) }
XdgShellV6 { onToplevelCreated: addShellSurface(xdgSurface) }
+ WlShell { onWlShellSurfaceCreated: addShellSurface(shellSurface) }
}
diff --git a/examples/wayland/minimal-qml/main.qml b/examples/wayland/minimal-qml/main.qml
index 85c8c5783..63ed9da5f 100644
--- a/examples/wayland/minimal-qml/main.qml
+++ b/examples/wayland/minimal-qml/main.qml
@@ -50,7 +50,7 @@
import QtQuick 2.6
import QtQuick.Window 2.2
-import QtWayland.Compositor 1.1
+import QtWayland.Compositor 1.3
WaylandCompositor {
// The output defines the screen.
@@ -75,7 +75,7 @@ WaylandCompositor {
}
}
// Extensions are additions to the core Wayland
- // protocol. We choose to support two different
+ // protocol. We choose to support three different
// shells (window management protocols). When the
// client creates a new shell surface (i.e. a window)
// we append it to our list of shellSurfaces.
@@ -87,5 +87,9 @@ WaylandCompositor {
onToplevelCreated:
shellSurfaces.append({shellSurface: xdgSurface});
}
+ XdgShell {
+ onToplevelCreated:
+ shellSurfaces.append({shellSurface: xdgSurface});
+ }
ListModel { id: shellSurfaces }
}
diff --git a/examples/wayland/multi-screen/qml/main.qml b/examples/wayland/multi-screen/qml/main.qml
index 354dd1c91..ecd32739d 100644
--- a/examples/wayland/multi-screen/qml/main.qml
+++ b/examples/wayland/multi-screen/qml/main.qml
@@ -52,7 +52,7 @@
import QtQml 2.2
import QtQuick 2.0
import QtQuick.Window 2.3 as Window
-import QtWayland.Compositor 1.1
+import QtWayland.Compositor 1.3
import QtQml.Models 2.1
WaylandCompositor {
@@ -104,6 +104,10 @@ WaylandCompositor {
onToplevelCreated: handleShellSurfaceCreated(xdgSurface)
}
+ XdgShell {
+ onToplevelCreated: handleShellSurfaceCreated(xdgSurface)
+ }
+
function createShellSurfaceItem(shellSurface, moveItem, output) {
var parentSurfaceItem = output.viewsBySurface[shellSurface.parentSurface];
var parent = parentSurfaceItem || output.surfaceArea;
diff --git a/examples/wayland/overview-compositor/main.qml b/examples/wayland/overview-compositor/main.qml
index 18589e50a..d0482a90e 100644
--- a/examples/wayland/overview-compositor/main.qml
+++ b/examples/wayland/overview-compositor/main.qml
@@ -49,7 +49,7 @@
****************************************************************************/
import QtQuick 2.7
-import QtWayland.Compositor 1.1
+import QtWayland.Compositor 1.3
import QtQuick.Window 2.3
import QtQuick.Controls 2.0
@@ -132,7 +132,7 @@ WaylandCompositor {
ListModel { id: toplevels }
- XdgShellV6 {
+ XdgShell {
onToplevelCreated: {
toplevels.append({xdgSurface});
toplevel.sendFullscreen(Qt.size(win.pixelWidth, win.pixelHeight));
diff --git a/examples/wayland/pure-qml/qml/main.qml b/examples/wayland/pure-qml/qml/main.qml
index b188ebbb5..69be7cf10 100644
--- a/examples/wayland/pure-qml/qml/main.qml
+++ b/examples/wayland/pure-qml/qml/main.qml
@@ -49,7 +49,7 @@
****************************************************************************/
import QtQuick 2.0
-import QtWayland.Compositor 1.1
+import QtWayland.Compositor 1.3
WaylandCompositor {
id: waylandCompositor
@@ -58,6 +58,11 @@ WaylandCompositor {
// Shell surface extension. Needed to provide a window concept for Wayland clients.
// I.e. requests and events for maximization, minimization, resizing, closing etc.
+ XdgShell {
+ onToplevelCreated: screen.handleShellSurface(xdgSurface)
+ }
+
+ // Unstable version of xdg-shell still used by some clients
XdgShellV6 {
onToplevelCreated: screen.handleShellSurface(xdgSurface)
}
diff --git a/examples/wayland/spanning-screens/main.qml b/examples/wayland/spanning-screens/main.qml
index a3230806b..ab57306bb 100644
--- a/examples/wayland/spanning-screens/main.qml
+++ b/examples/wayland/spanning-screens/main.qml
@@ -50,7 +50,7 @@
import QtQuick 2.6
import QtQuick.Window 2.3
-import QtWayland.Compositor 1.1
+import QtWayland.Compositor 1.3
WaylandCompositor {
WaylandOutput {
@@ -105,7 +105,7 @@ WaylandCompositor {
}
}
- XdgShellV6 {
+ XdgShell {
onToplevelCreated: {
const shellSurface = xdgSurface;