From 6a175ece489a36a47ea4700326c8beaed52a3379 Mon Sep 17 00:00:00 2001 From: Vlad Zagorodniy Date: Thu, 21 Jun 2018 11:15:08 +0300 Subject: [PATCH] [libkwineffects] Add keepBelow property to EffectWindow Summary: EffectWindow has keepAbove property, but not keepBelow. This change adds keepBelow property as a counterpart to keepAbove. Test Plan: Manually. Reviewers: #kwin, mart Reviewed By: #kwin, mart Subscribers: kwin Tags: #kwin Differential Revision: https://phabricator.kde.org/D13650 --- libkwineffects/kwineffects.cpp | 1 + libkwineffects/kwineffects.h | 8 ++++++++ 2 files changed, 9 insertions(+) diff --git a/libkwineffects/kwineffects.cpp b/libkwineffects/kwineffects.cpp index 1330b3cc83..a8c79f3108 100644 --- a/libkwineffects/kwineffects.cpp +++ b/libkwineffects/kwineffects.cpp @@ -861,6 +861,7 @@ WINDOW_HELPER_DEFAULT(bool, isMovable, "moveable", false) WINDOW_HELPER_DEFAULT(bool, isMovableAcrossScreens, "moveableAcrossScreens", false) WINDOW_HELPER_DEFAULT(QString, caption, "caption", QString()) WINDOW_HELPER_DEFAULT(bool, keepAbove, "keepAbove", true) +WINDOW_HELPER_DEFAULT(bool, keepBelow, "keepBelow", false) WINDOW_HELPER_DEFAULT(bool, isModal, "modal", false) WINDOW_HELPER_DEFAULT(QSize, basicUnit, "basicUnit", QSize(1, 1)) WINDOW_HELPER_DEFAULT(bool, isUserMove, "move", false) diff --git a/libkwineffects/kwineffects.h b/libkwineffects/kwineffects.h index ea540e9a01..2455cb3623 100644 --- a/libkwineffects/kwineffects.h +++ b/libkwineffects/kwineffects.h @@ -1836,6 +1836,10 @@ class KWINEFFECTS_EXPORT EffectWindow : public QObject * Whether the window is set to be kept above other windows. **/ Q_PROPERTY(bool keepAbove READ keepAbove) + /** + * Whether the window is set to be kept below other windows. + **/ + Q_PROPERTY(bool keepBelow READ keepBelow) /** * Whether the window is minimized. **/ @@ -2140,6 +2144,10 @@ public: * Returns whether or not the window is kept above all other windows. */ bool keepAbove() const; + /** + * Returns whether the window is kept below all other windows. + */ + bool keepBelow() const; bool isModal() const; Q_SCRIPTABLE virtual KWin::EffectWindow* findModal() = 0;