fix compilation with no-deprecated build of kwindowsystem
I build kwindowsystem with -DEXCLUDE_DEPRECATED_BEFORE_AND_AT=5.62.0, and this broke here. Use the exact same condition as the one around those virtual methods in the base class. Same fix as https://phabricator.kde.org/D25488
This commit is contained in:
parent
1be9594aff
commit
2f000e3df4
2 changed files with 12 additions and 3 deletions
|
@ -107,7 +107,7 @@ QPoint WindowSystem::desktopToViewport(int desktop, bool absolute)
|
|||
return QPoint();
|
||||
}
|
||||
|
||||
#ifndef KWINDOWSYSTEM_NO_DEPRECATED
|
||||
#if KWINDOWSYSTEM_BUILD_DEPRECATED_SINCE(5, 0)
|
||||
WId WindowSystem::groupLeader(WId window)
|
||||
{
|
||||
Q_UNUSED(window)
|
||||
|
@ -287,7 +287,7 @@ QList< WId > WindowSystem::stackingOrder()
|
|||
return {};
|
||||
}
|
||||
|
||||
#ifndef KWINDOWSYSTEM_NO_DEPRECATED
|
||||
#if KWINDOWSYSTEM_BUILD_DEPRECATED_SINCE(5, 0)
|
||||
WId WindowSystem::transientFor(WId window)
|
||||
{
|
||||
Q_UNUSED(window)
|
||||
|
|
|
@ -23,6 +23,15 @@
|
|||
|
||||
#include <QObject>
|
||||
|
||||
// Compat with KF < 5.64
|
||||
#ifndef KWINDOWSYSTEM_BUILD_DEPRECATED_SINCE
|
||||
#ifndef KWINDOWSYSTEM_NO_DEPRECATED
|
||||
#define KWINDOWSYSTEM_BUILD_DEPRECATED_SINCE(x, y) 1
|
||||
#else
|
||||
#define KWINDOWSYSTEM_BUILD_DEPRECATED_SINCE(x, y) 0
|
||||
#endif
|
||||
#endif
|
||||
|
||||
namespace KWin
|
||||
{
|
||||
|
||||
|
@ -44,7 +53,7 @@ public:
|
|||
void setOnAllDesktops(WId win, bool b) override;
|
||||
void setOnDesktop(WId win, int desktop) override;
|
||||
void setOnActivities(WId win, const QStringList &activities) override;
|
||||
#ifndef KWINDOWSYSTEM_NO_DEPRECATED
|
||||
#if KWINDOWSYSTEM_BUILD_DEPRECATED_SINCE(5, 0)
|
||||
WId transientFor(WId window) override;
|
||||
WId groupLeader(WId window) override;
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue