Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement mouse scrolling on topbar to scroll viewport #883

Merged
merged 8 commits into from
Jun 27, 2024

Conversation

jtaala
Copy link
Collaborator

@jtaala jtaala commented Jun 26, 2024

Implements #206.

Allows switching windows with mouse scrolling on the gnome topbar.

@jtaala
Copy link
Collaborator Author

jtaala commented Jun 26, 2024

Note: it currently doesn't work well with the Gnome pill icon (events getting intercepted and it gets a bit confused).

I believe I've now fixed this.

@jtaala jtaala linked an issue Jun 26, 2024 that may be closed by this pull request
@jtaala
Copy link
Collaborator Author

jtaala commented Jun 26, 2024

See #881.

@jtaala jtaala requested a review from Lythenas June 26, 2024 15:18
@grota
Copy link

grota commented Jun 26, 2024

tested and it works, thank you!

@jtaala jtaala added the merging soon Label for PRs that are planned to be merged soon (usually within the next week) label Jun 26, 2024
@jtaala
Copy link
Collaborator Author

jtaala commented Jun 26, 2024

@Thesola10, can I get you to test this one out on a touchscreen? We're making the topbar reactive in this PR - don't think it would interfere with the touchscreen stuff but we better check.

Now using Main.panel (which is already reactive). I have move the touchscreen signals from captured-event to touch-event though (for efficiency as captured-event captures every single event and is heavy. Let me know if you see any issues on the latest commit here.

jtaala added 2 commits June 27, 2024 20:21
panelbox). Changed `captured-event` to `touch-event` for touch based
signals.  Linter cleanup.
@jtaala jtaala merged commit c73087e into develop Jun 27, 2024
@jtaala jtaala deleted the implement-206-scroll-windows-mouse branch June 27, 2024 13:08
@Thesola10
Copy link
Collaborator

touch-event used to cause issues with the scroll event where for some reason the selected window frame would update, but not the window itself. It seems to have been resolved

Seems however like the scroll handling is conflicting with vertical workspaces extensions such as V-Shell, just a heads-up

(that would have been an approving review :p)

@jtaala
Copy link
Collaborator Author

jtaala commented Jun 27, 2024

Seems however like the scroll handling is conflicting with vertical workspaces extensions such as V-Shell, just a heads-up

Thanks @Thesola10. Hmm - I suppose we can make the topbar scroll handling an option (so users can disable it - if it messes with v-shell or other extensions).

@jtaala
Copy link
Collaborator Author

jtaala commented Jun 27, 2024

hmm... it might be that we're return Clutter.EVENT_STOP; to our handling on the topbar doesn't bubble the events (once we handle them).

What are you seeing in V-Shell that's busted? (just so I can debug and check if the above fixes it).

@Thesola10
Copy link
Collaborator

it seems both PaperWM and V-Shell try to handle the scroll wheel event, sometimes the PaperWM selection is moving but mostly V-Shell wins.

Then again, maybe it's a Dash to Panel thing, but nothing is "broken" per se.

@jtaala
Copy link
Collaborator Author

jtaala commented Jun 27, 2024

hmm - seems v-shell is working fine for me. Will have a quick looksy at dash-to-panel.

@jtaala
Copy link
Collaborator Author

jtaala commented Jun 27, 2024

eh, either way it might be worth adding an option to disable the topbar scrolling.

jtaala added a commit that referenced this pull request Jun 27, 2024
…nsions (#886)

@Thesola10 mentioned some potential conflicts with the new mouse
scrolling (on topbar) feature (#883) and other extensions (e.g. V-Shell
and/or dash-to-panel).

Small change in how PaperWM: propagate scroll-event signal after
switching windows (in case other extensions require the event).

Not sure if it will make a difference though.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merging soon Label for PRs that are planned to be merged soon (usually within the next week)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Scroll windows with mouse wheel
3 participants