From 77bf51c3b537c0cdfd48be37b98e59c6078b57ff Mon Sep 17 00:00:00 2001 From: Vlad Zahorodnii Date: Tue, 7 Feb 2023 19:36:20 +0000 Subject: [PATCH] effects/overview: Drop "blur background" option The blur effect is used to improve the contrast. The option was added thinking "why not? it might be useful." This was perhaps a mistake and it should have been added with a clear valid usecase in mind. CCBUG: 457495 --- src/effects/overview/kcm/overvieweffectkcm.ui | 40 +++++++------------ src/effects/overview/overviewconfig.kcfg | 4 -- src/effects/overview/overvieweffect.cpp | 14 ------- src/effects/overview/overvieweffect.h | 6 --- src/effects/overview/qml/ScreenView.qml | 2 +- 5 files changed, 16 insertions(+), 50 deletions(-) diff --git a/src/effects/overview/kcm/overvieweffectkcm.ui b/src/effects/overview/kcm/overvieweffectkcm.ui index e746ddc0b1..fffb5805f3 100644 --- a/src/effects/overview/kcm/overvieweffectkcm.ui +++ b/src/effects/overview/kcm/overvieweffectkcm.ui @@ -37,7 +37,21 @@ - + + + + Ignore minimized windows: + + + + + + + + + + + @@ -50,30 +64,6 @@ - - - - Blur background: - - - - - - - - - - - - - - - - - Ignore minimized windows: - - - diff --git a/src/effects/overview/overviewconfig.kcfg b/src/effects/overview/overviewconfig.kcfg index d2b9d83307..03f4fe0351 100644 --- a/src/effects/overview/overviewconfig.kcfg +++ b/src/effects/overview/overviewconfig.kcfg @@ -17,10 +17,6 @@ false - - true - - diff --git a/src/effects/overview/overvieweffect.cpp b/src/effects/overview/overvieweffect.cpp index 313e394ebc..0b6d99d3a5 100644 --- a/src/effects/overview/overvieweffect.cpp +++ b/src/effects/overview/overvieweffect.cpp @@ -93,7 +93,6 @@ void OverviewEffect::reconfigure(ReconfigureFlags) OverviewConfig::self()->read(); setLayout(OverviewConfig::layoutMode()); setAnimationDuration(animationTime(300)); - setBlurBackground(OverviewConfig::blurBackground()); for (const ElectricBorder &border : std::as_const(m_borderActivate)) { effects->unreserveElectricBorder(border, this); @@ -160,19 +159,6 @@ void OverviewEffect::setLayout(int layout) } } -bool OverviewEffect::blurBackground() const -{ - return m_blurBackground; -} - -void OverviewEffect::setBlurBackground(bool blur) -{ - if (m_blurBackground != blur) { - m_blurBackground = blur; - Q_EMIT blurBackgroundChanged(); - } -} - qreal OverviewEffect::partialActivationFactor() const { return m_partialActivationFactor; diff --git a/src/effects/overview/overvieweffect.h b/src/effects/overview/overvieweffect.h index 88158f42c5..7dba6fe0e5 100644 --- a/src/effects/overview/overvieweffect.h +++ b/src/effects/overview/overvieweffect.h @@ -17,7 +17,6 @@ class OverviewEffect : public QuickSceneEffect Q_PROPERTY(int animationDuration READ animationDuration NOTIFY animationDurationChanged) Q_PROPERTY(int layout READ layout NOTIFY layoutChanged) Q_PROPERTY(bool ignoreMinimized READ ignoreMinimized NOTIFY ignoreMinimizedChanged) - Q_PROPERTY(bool blurBackground READ blurBackground NOTIFY blurBackgroundChanged) Q_PROPERTY(qreal partialActivationFactor READ partialActivationFactor NOTIFY partialActivationFactorChanged) // More efficient from a property binding pov rather than binding to partialActivationFactor !== 0 Q_PROPERTY(bool gestureInProgress READ gestureInProgress NOTIFY gestureInProgressChanged) @@ -41,9 +40,6 @@ public: int animationDuration() const; void setAnimationDuration(int duration); - bool blurBackground() const; - void setBlurBackground(bool blur); - qreal partialActivationFactor() const; void setPartialActivationFactor(qreal factor); @@ -58,7 +54,6 @@ public: Q_SIGNALS: void animationDurationChanged(); void layoutChanged(); - void blurBackgroundChanged(); void partialActivationFactorChanged(); void gestureInProgressChanged(); void ignoreMinimizedChanged(); @@ -89,7 +84,6 @@ private: QString m_searchText; Status m_status = Status::Inactive; qreal m_partialActivationFactor = 0; - bool m_blurBackground = false; int m_animationDuration = 400; int m_layout = 1; bool m_gestureInProgress = false; diff --git a/src/effects/overview/qml/ScreenView.qml b/src/effects/overview/qml/ScreenView.qml index 8f55e02816..0b78453c5f 100644 --- a/src/effects/overview/qml/ScreenView.qml +++ b/src/effects/overview/qml/ScreenView.qml @@ -81,7 +81,7 @@ FocusScope { outputName: targetScreen.name property real blurRadius: 0 - layer.enabled: effect.blurBackground + layer.enabled: true layer.effect: FastBlur { radius: backgroundItem.blurRadius }