https://bugs.kde.org/show_bug.cgi?id=482428

Jakob Petsovits <jpe...@petsovits.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
      Latest Commit|                            |https://invent.kde.org/plas
                   |                            |ma/powerdevil/-/commit/5114
                   |                            |69e52d4676d6c71f66acaaf277a
                   |                            |7efc25e1e
             Status|ASSIGNED                    |RESOLVED

--- Comment #6 from Jakob Petsovits <jpe...@petsovits.com> ---
Git commit 511469e52d4676d6c71f66acaaf277a7efc25e1e by Jakob Petsovits.
Committed on 22/05/2024 at 04:36.
Pushed by jpetso into branch 'master'.

kcmodule: Switch to comboboxes for selecting idle timeout values

This follows the direction spearheaded by kcm_screenlocker,
in plasma/kscreenlocker commit 311db2a9. In addition to a few
select preset options, the user can also select a "Custom…"
option which presents a duration prompt dialog.

Using comboboxes has a few nice UX characteristics:

* It allows us to replace the checkbox of some timeout settings
  with a textual option called "Never", which is easier to grasp.
  Likewise, "Immediately" is more obvious than "0 sec".

* It increases the mouse area available for clicking, which makes
  the control easier to hit for users with low-precision pointer
  input devices.

* It sidesteps the problem of SpinBox ignoring the defined
  step size when scrolling with a high-resolution scroll wheel.

* By putting the SpinBox into a custom duration prompt dialog,
  it's more obvious that both seconds and minutes are supported
  for each setting. Some options also provide second-level presets.

The downside is that it now takes three extra clicks to enter
and confirm a custom timeout duration. Hopefully our users are
comfortable with that trade-off.

In order to implement this, the latest versions of the
ComboBoxWithCustomValue and DurationPromptDialog components
are copied from kcm_screenlocker. Several improvements to these
components will be fed back to kcm_screenlocker and hopefully
upstreamed to Kirigami (or Kirigami Addons) at a later time.

In addition, this commit introduces TimeDurationComboBox, a glue code
component combining two aforementioned components, to further
reduce the amount of boilerplate required in ProfileConfig.qml.
Related: bug 482853

A  +164  -0    kcmodule/profiles/ui/ComboBoxWithCustomValue.qml     [License:
LGPL(v2.1+)]
A  +212  -0    kcmodule/profiles/ui/DurationPromptDialog.qml     [License:
LGPL(v2.1+)]
M  +264  -104  kcmodule/profiles/ui/ProfileConfig.qml
D  +0    -49   kcmodule/profiles/ui/TimeDelaySpinBox.qml
A  +151  -0    kcmodule/profiles/ui/TimeDurationComboBox.qml     [License:
LGPL(v2.1+)]

https://invent.kde.org/plasma/powerdevil/-/commit/511469e52d4676d6c71f66acaaf277a7efc25e1e

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to