Skip to content

Add Options+-style workspace scrubbing for the thumb wheel - #169

Open
asdolo wants to merge 1 commit into
mmaher88:masterfrom
asdolo:feat/workspace-thumb-wheel
Open

asdolo wants to merge 1 commit into
mmaher88:masterfrom
asdolo:feat/workspace-thumb-wheel

Conversation

@asdolo

@asdolo asdolo commented Oct 25, 2026

Copy link
Copy Markdown

Summary

  • Adds a GNOME Shell workspace-gesture extension and Logitune wiring so the MX Master thumb wheel can scrub desktops Options+-style (hold while touching, snap on release).
  • UI for Switch desktops includes Normal/Inverted direction and a configurable commit threshold (10–90%).
  • Parses HID++ 0x2150 Stop/touch so release ends the gesture; eases to the threshold target before finishing so the lift-off animation stays smooth.

Test plan

  • Build/install Logitune; enable logitune-workspace@logitune.com (or let Logitune sync/enable it)
  • Set thumb wheel to Switch desktops; scrub and hold with thumb down — overlay should stay; lift — animation should ease to the snap
  • Toggle Normal / Inverted and confirm direction flips
  • Lower Switch after to ~20–25% and confirm a short scrub commits; raise toward 50%+ and confirm more travel is needed
  • Multi-monitor: scrub still switches the global workspace (GNOME model)
  • logitune-tests filter ButtonActionDispatcherFixture.Workspace* / ThumbWheel.ParseEvent* pass

Hold-to-scrub on GNOME Wayland with release snap, configurable direction
and commit threshold, so MX Master users can switch desktops the same way
they do in Logi Options+.

@mmaher88 mmaher88 left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is an ambitious feature, and the HID++ 0x2150 Stop/touch parsing is a nice addition. It's a lot for one PR, though. Could you split it into:

  • (a) the 0x2150 event parsing and thumbWheelReleased, which is close to mergeable;
  • (b) a "Switch desktops" mode that works on any desktop through the presets;
  • (c) the GNOME interactive extension.

Blocking issues:

  • The RPM %files in pkg/obs/logitune.spec must list the new logitune-workspace@ folder, or the OBS builds fail.
  • Every qBound call has its arguments reversed (Qt's order is qBound(min, value, max)), which asserts in debug builds for values over 90.
  • findExtensionSourceDir has fallbacks that ignore the extension ID, so it can copy the workspace extension over logitune-focus@.
  • The refactor drops the stale user-copy cleanup from 3f03e55.

On design:

  • C++ and the extension each track progress, but only the Shell clamps at the first and last workspace, so snapping goes wrong after overshooting an edge. Please let the extension own progress, take snapPercent in End, and drop the C++ easing.
  • End an active scrub whenever Stop arrives or a profile is applied, whatever the current mode, and add a watchdog in the extension (or watch our D-Bus name) so the Shell can't be left mid-switch.
  • The preset fallback switches a desktop every 15 thumb units, which jumps several desktops per flick. Please use a much larger step or one switch per roll, and hide the mode on desktops that can't do it.
  • The extension uses private Shell internals and is installed for every GNOME user at start-up. Please make it opt-in when the mode is selected, and list only the Shell versions you've tested.

After that, a rebase onto #174's per-device slots is needed (PhysicalDevice* arguments and a lambda in AppRoot).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants