Skip to content

Draft: Only change control values with scroll when focused

Draft because I'm waiting to see what happens with kirigami!415 (merged).


Allowing controls to handle scroll events to change their values creates an un-resolvable UX conflict because sliders can be embedded into a scrollable view, and in this case, scrolling the view will unexpectedly change the values of any sliders that the cursor happens to pass over while the view is updating. This is especially severe for views with wide sliders that take up most or all of the horizontal space in a scrollable view, wherein scroll behavior is completely broken due to the conflict. The plasma-pa KCM is one such example.

Disabling this behavior seems like an obvious solution, but inevitably we will discover the few users who use and like this behavior nd get complaints about it. So instead, this commit does something a bit tricky: it enables the behavior only if the control is focused. This allows you to focus a control to fine-tune its value with a scroll, but unfocused controls will ignore scroll events to avoid the conflict between "view scroll" and "change control values scroll".

BUG: 417211 BUG: 446014 FIXED-IN: 5.89

To test:

  • Scroll on the Audio Volume KCM while it has enough devices to be scrollable and don't get driven mad
  • Focus a combobox on that page and scroll over it and see that it works

cc @teams/usability

Edited by Nate Graham

Merge request reports

Loading