From 37f65cf186f9442c85f53fdf53e074f4625bcdd6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Thu, 24 Mar 2016 15:30:48 +0100 Subject: [PATCH] [server] Add const variants to methods in SubSurfaceInterface Summary: Fixes errors in API of methods which should be const not being const. Reviewers: #plasma Subscribers: plasma-devel Projects: #plasma Differential Revision: https://phabricator.kde.org/D1214 --- src/wayland/subcompositor_interface.cpp | 14 ++++++++++++++ src/wayland/subcompositor_interface.h | 12 ++++++++++++ 2 files changed, 26 insertions(+) diff --git a/src/wayland/subcompositor_interface.cpp b/src/wayland/subcompositor_interface.cpp index 9c77a5a3c4..dbdce927da 100644 --- a/src/wayland/subcompositor_interface.cpp +++ b/src/wayland/subcompositor_interface.cpp @@ -294,12 +294,26 @@ QPoint SubSurfaceInterface::position() const } QPointer SubSurfaceInterface::surface() +{ + // TODO: remove with ABI break (KF6) + Q_D(); + return d->surface; +} + +QPointer SubSurfaceInterface::surface() const { Q_D(); return d->surface; } QPointer SubSurfaceInterface::parentSurface() +{ + // TODO: remove with ABI break (KF6) + Q_D(); + return d->parent; +} + +QPointer SubSurfaceInterface::parentSurface() const { Q_D(); return d->parent; diff --git a/src/wayland/subcompositor_interface.h b/src/wayland/subcompositor_interface.h index 674ea1d89d..2d9a4511f9 100644 --- a/src/wayland/subcompositor_interface.h +++ b/src/wayland/subcompositor_interface.h @@ -82,8 +82,20 @@ public: **/ bool isSynchronized() const; + // TODO: remove with ABI break (KF6) QPointer surface(); + /** + * @returns The surface this SubSurfaceInterface was created on. + * @since 5.7 + **/ + QPointer surface() const; + // TODO: remove with ABI break (KF6) QPointer parentSurface(); + /** + * @returns The parent surface for which this SubSurfaceInterface is a child + * @since 5.7 + **/ + QPointer parentSurface() const; /** * @returns the main surface for the sub-surface tree, that is the first surface without a parent