From 616783d892db0410497356409698a81311610fc6 Mon Sep 17 00:00:00 2001 From: Noah Davis Date: Tue, 11 Apr 2023 12:41:23 -0400 Subject: [PATCH] Blacklist Spectacle for all window open/close effects Spectacle needs to be blacklisted in order to stay out of its own screenshots. BUG: 467890 BUG: 463105 CCBUG: 465784 --- src/effects/fade/package/contents/code/main.js | 6 +++++- src/effects/glide/glide.cpp | 3 +++ src/effects/scale/package/contents/code/main.js | 6 +++++- 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/src/effects/fade/package/contents/code/main.js b/src/effects/fade/package/contents/code/main.js index b0c3fc4a3e..a9600f295f 100644 --- a/src/effects/fade/package/contents/code/main.js +++ b/src/effects/fade/package/contents/code/main.js @@ -15,7 +15,11 @@ const blacklist = [ "ksmserver-logout-greeter ksmserver-logout-greeter", // The splash screen has to be animated only by the login effect. - "ksplashqml ksplashqml" + "ksplashqml ksplashqml", + + // Spectacle needs to be blacklisted in order to stay out of its own screenshots. + "spectacle spectacle", // x11 + "spectacle org.kde.spectacle", // wayland ]; class FadeEffect { diff --git a/src/effects/glide/glide.cpp b/src/effects/glide/glide.cpp index c297a2a7ba..784fc114ad 100644 --- a/src/effects/glide/glide.cpp +++ b/src/effects/glide/glide.cpp @@ -33,6 +33,9 @@ static const QSet s_blacklist{ QStringLiteral("ksmserver ksmserver"), QStringLiteral("ksmserver-logout-greeter ksmserver-logout-greeter"), QStringLiteral("ksplashqml ksplashqml"), + // Spectacle needs to be blacklisted in order to stay out of its own screenshots. + QStringLiteral("spectacle spectacle"), // x11 + QStringLiteral("spectacle org.kde.spectacle"), // wayland }; static QMatrix4x4 createPerspectiveMatrix(const QRectF &rect, const qreal scale, const QMatrix4x4 &renderTargetTransformation) diff --git a/src/effects/scale/package/contents/code/main.js b/src/effects/scale/package/contents/code/main.js index eb97629b0e..32a3b2e652 100644 --- a/src/effects/scale/package/contents/code/main.js +++ b/src/effects/scale/package/contents/code/main.js @@ -15,7 +15,11 @@ const blacklist = [ "ksmserver-logout-greeter ksmserver-logout-greeter", // KDE Plasma splash screen has to be animated only by the login effect. - "ksplashqml ksplashqml" + "ksplashqml ksplashqml", + + // Spectacle needs to be blacklisted in order to stay out of its own screenshots. + "spectacle spectacle", // x11 + "spectacle org.kde.spectacle", // wayland ]; class ScaleEffect {