From 3f55c23aff3eb9295c1b92deee6e7eee0dcafb74 Mon Sep 17 00:00:00 2001 From: Simon Schneegans Date: Thu, 22 Dec 2022 21:21:39 +0100 Subject: [PATCH] :beetle: Fix KWin portal effect config UI --- kwin/portal/config.ui | 214 ++++++++++++++++++++----------- kwin/portal/onSettingsChanged.js | 6 +- 2 files changed, 143 insertions(+), 77 deletions(-) diff --git a/kwin/portal/config.ui b/kwin/portal/config.ui index f1e7281..b25ce67 100755 --- a/kwin/portal/config.ui +++ b/kwin/portal/config.ui @@ -1,77 +1,143 @@ - - - - BMWConfigForm - - - - 0 - 0 - 562 - 365 - - - - - - - Duration: - - - Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter - - - - - - - Color: - - - Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter - - - kcfg_Color - - - - - - - true - - - - - - - milliseconds - - - 100 - - - 9999 - - - 100 - - - - + BMWConfigForm + + + + 0 + 0 + 562 + 365 + + + + + + + Color: + + + Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter + + + kcfg_Color + - - - KColorButton - QPushButton -
kcolorbutton.h
-
-
- - -
\ No newline at end of file + + + + + Duration: + + + Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter + + + + + + + Rotation Speed + + + Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter + + + + + + + milliseconds + + + 1000 + + + 5000 + + + 100 + + + + + + + true + + + + + + + Whirl + + + Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter + + + + + + + Details + + + Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter + + + + + + + 1.000000000000000 + + + 100.000000000000000 + + + + + + + -2.000000000000000 + + + 2.000000000000000 + + + 0.100000000000000 + + + QAbstractSpinBox::AdaptiveDecimalStepType + + + + + + + -2.000000000000000 + + + 2.000000000000000 + + + 0.100000000000000 + + + QAbstractSpinBox::AdaptiveDecimalStepType + + + + + + + + KColorButton + QPushButton +
kcolorbutton.h
+
+
+ + + diff --git a/kwin/portal/onSettingsChanged.js b/kwin/portal/onSettingsChanged.js index bcfb6be..35c2818 100644 --- a/kwin/portal/onSettingsChanged.js +++ b/kwin/portal/onSettingsChanged.js @@ -7,6 +7,6 @@ effect.setUniform(this.shader, 'uDuration', this.duration * 0.001); effect.setUniform(this.shader, 'uColor', this.readRGBConfig('Color')); -effect.setUniform(this.shader, 'uDetails', this.readConfig('Details', 1.0)); -effect.setUniform(this.shader, 'uRotationSpeed', this.readConfig('RotationSpeed', 1.0)); -effect.setUniform(this.shader, 'uWhirl', this.readConfig('Whirl', 1.0)); \ No newline at end of file +effect.setUniform(this.shader, 'uDetails', effect.readConfig('Details', 1.0)); +effect.setUniform(this.shader, 'uRotationSpeed', effect.readConfig('RotationSpeed', 1.0)); +effect.setUniform(this.shader, 'uWhirl', effect.readConfig('Whirl', 1.0));