File: 0059-Client-Call-wl_output_release-upon-QWaylandScreen-de.patch

package info (click to toggle)
qtwayland-opensource-src 5.15.17-1
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 11,108 kB
  • sloc: cpp: 53,691; xml: 9,462; ansic: 187; makefile: 29; sh: 5
file content (26 lines) | stat: -rw-r--r-- 940 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
From a2c4483f7205dd96f1f84c3e94ce4e85583a22e7 Mon Sep 17 00:00:00 2001
From: Vlad Zahorodnii <vlad.zahorodnii@kde.org>
Date: Mon, 21 Nov 2022 18:39:40 +0200
Subject: [PATCH] Client: Call wl_output_release() upon QWaylandScreen
 destruction

It ensures that the proxy gets destroyed.

Change-Id: I915cc8814e33dd3b0405b2bf82bd12ce6b5f785b
Reviewed-by: David Edmundson <davidedmundson@kde.org>
(cherry picked from commit 054e54759dbd6c3e76b55d5c4a9a54f62967ad1a)
---
 src/client/qwaylandscreen.cpp | 2 ++
 1 file changed, 2 insertions(+)

--- a/src/client/qwaylandscreen.cpp
+++ b/src/client/qwaylandscreen.cpp
@@ -81,6 +81,8 @@ QWaylandScreen::~QWaylandScreen()
 {
     if (zxdg_output_v1::isInitialized())
         zxdg_output_v1::destroy();
+    if (wl_output::isInitialized() && wl_output_get_version(wl_output::object()) >= WL_OUTPUT_RELEASE_SINCE_VERSION)
+        wl_output::release();
 }
 
 uint QWaylandScreen::requiredEvents() const