File indexing completed on 2024-07-14 14:38:31

0001 /*
0002     SPDX-FileCopyrightText: 2014 Martin Gräßlin <mgraesslin@kde.org>
0003 
0004     SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
0005 */
0006 
0007 #ifndef KWINDOWEFFECTS_P_H
0008 #define KWINDOWEFFECTS_P_H
0009 #include "kwindoweffects.h"
0010 
0011 class KWINDOWSYSTEM_EXPORT KWindowEffectsPrivate
0012 {
0013 public:
0014     virtual ~KWindowEffectsPrivate();
0015     virtual bool isEffectAvailable(KWindowEffects::Effect effect) = 0;
0016     virtual void slideWindow(WId id, KWindowEffects::SlideFromLocation location, int offset) = 0;
0017 #if KWINDOWSYSTEM_BUILD_DEPRECATED_SINCE(5, 81)
0018     virtual QList<QSize> windowSizes(const QList<WId> &ids) = 0;
0019 #endif
0020 #if KWINDOWSYSTEM_BUILD_DEPRECATED_SINCE(5, 82)
0021     virtual void presentWindows(WId controller, const QList<WId> &ids) = 0;
0022     virtual void presentWindows(WId controller, int desktop = NET::OnAllDesktops) = 0;
0023     virtual void highlightWindows(WId controller, const QList<WId> &ids) = 0;
0024 #endif
0025     virtual void enableBlurBehind(WId window, bool enable = true, const QRegion &region = QRegion()) = 0;
0026     virtual void enableBackgroundContrast(WId window,
0027                                           bool enable = true,
0028                                           qreal contrast = 1,
0029                                           qreal intensity = 1,
0030                                           qreal saturation = 1,
0031                                           const QRegion &region = QRegion()) = 0;
0032 #if KWINDOWSYSTEM_BUILD_DEPRECATED_SINCE(5, 67)
0033     virtual void markAsDashboard(WId window) = 0;
0034 #endif
0035 protected:
0036     KWindowEffectsPrivate();
0037 };
0038 
0039 class KWINDOWSYSTEM_EXPORT KWindowEffectsPrivateV2 : public KWindowEffectsPrivate
0040 {
0041 public:
0042     virtual void setBackgroundFrost(QWindow *window, QColor color, const QRegion &region = QRegion()) = 0;
0043 
0044 protected:
0045     KWindowEffectsPrivateV2();
0046     ~KWindowEffectsPrivateV2() override;
0047 };
0048 
0049 #endif