diff --git a/kcms/launch/package/contents/ui/main.qml b/kcms/launch/package/contents/ui/main.qml --- a/kcms/launch/package/contents/ui/main.qml +++ b/kcms/launch/package/contents/ui/main.qml @@ -31,6 +31,8 @@ Kirigami.FormLayout { id: formLayout + readonly property bool cursorImmutable: kcm.launchFeedbackSettings.isImmutable("busyCursor") || kcm.launchFeedbackSettings.isImmutable("blinking") || kcm.launchFeedbackSettings.isImmutable("bouncing") + function setCursorSettings(feedback) { kcm.launchFeedbackSettings.busyCursor = feedback !== Private.KCM.None kcm.launchFeedbackSettings.blinking = feedback === Private.KCM.Blinking @@ -40,6 +42,7 @@ QtControls.RadioButton { id: busyCursorDisabled + enabled: !formLayout.cursorImmutable Kirigami.FormData.label: i18n("Cursor:") text: i18n("No Feedback") checked: !kcm.launchFeedbackSettings.busyCursor && !kcm.launchFeedbackSettings.blinking && !kcm.launchFeedbackSettings.bouncing @@ -49,30 +52,34 @@ QtControls.RadioButton { id: busyCursorStatic + enabled: !formLayout.cursorImmutable text: i18n("Static") checked: kcm.launchFeedbackSettings.busyCursor && !kcm.launchFeedbackSettings.blinking && !kcm.launchFeedbackSettings.bouncing onToggled: formLayout.setCursorSettings(Private.KCM.Static) } QtControls.RadioButton { id: busyCursorBlinking + enabled: !formLayout.cursorImmutable text: i18n("Blinking") checked: kcm.launchFeedbackSettings.busyCursor && kcm.launchFeedbackSettings.blinking && !kcm.launchFeedbackSettings.bouncing onToggled: formLayout.setCursorSettings(Private.KCM.Blinking) } QtControls.RadioButton { id: busyCursorBouncing + enabled: !formLayout.cursorImmutable text: i18n("Bouncing") checked: kcm.launchFeedbackSettings.busyCursor && !kcm.launchFeedbackSettings.blinking && kcm.launchFeedbackSettings.bouncing onToggled: formLayout.setCursorSettings(Private.KCM.Bouncing) } QtControls.CheckBox { id: taskManagerNotification + enabled: !kcm.launchFeedbackSettings.isImmutable("taskbarButton") Kirigami.FormData.label: i18n("Task Manager:") text: i18n("Enable animation") @@ -89,7 +96,7 @@ stepSize: 1 editable: true - enabled: taskManagerNotification.checked + enabled: taskManagerNotification.checked && !kcm.launchFeedbackSettings.isImmutable("cursorTimeout") value: kcm.launchFeedbackSettings.cursorTimeout onValueModified: {