-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
toggle the menubar with single Alt key press #11304
Conversation
0c74aec
to
801c55c
Compare
801c55c
to
075b7aa
Compare
075b7aa
to
8eee847
Compare
8eee847
to
c5c992f
Compare
67ef039
to
a8f2138
Compare
Now this works flawlessly on both 20.04 with xfce and 22.04 with Unity. |
Automatically focusing the Okay button does not work on all platforms, yet. |
a8f2138
to
4e74af1
Compare
I've been using this + #11313 without and have any issues (Ubuntu 20.04 with vala global menu). edit macOS testing would be nice, too, but the changes |
Works good here on Ubuntu Focal. The popup window can be improved for keyboard interactions. |
I did a short test on Windows 11 and it works as expected! |
Great, thanks for testing!
Yeah, I still have to polish the dialog.
I don't understand... Alt+F is just an example, here all keys work and unhide the menu bar.
Yes, entirely. |
It is just that in case of a standard QMessageBox, the O if OK is underlined for pressing the button via Alt+O. |
4e74af1
to
140e581
Compare
140e581
to
232b8c1
Compare
23fc9ce
to
74751ec
Compare
(responding to @daschuer's review comment in #11313 )
Users are notified how to toggle the menubar when going fullscreen, so they should know how to get it back in windowed mode. But indeed this is inconsistent with showing the menubar on each (windowed) start. Anyway, allowing to toggle the menubar is a significant change and we may make a step backwards and discuss the implementation options and how to let as many users as possible benefit from it.
So the Okay button is not focused when the hint pops up? |
The more I think about it I notice I prefer the way it's done in Firefox:
+
I'll test this in another branch so the different approaches can be tested easily. |
This modal popup is displayed every time when going fullscreen as long as the "Remind me again" checkbox is ticked when Okay is clicked. It can be styled to match the skin.
74751ec
to
af2cfcb
Compare
I'll close this one in favor of #11526 |
I decided to make another attempt to hide the menubar, this time by filtering a single Alt keypress + the essentials from #3184, but without the ControlObject and the skin button.
This is not available on macOS since there's a permanent global menu, also in fullcreen mode
I decided to require a single Alt press so Alt bindings in custom keyboard mappings don't toggle the menubar.
TODO
that action is not clickable (or does nothing respectively), so users have to press Alt themselves
I wonder if that should be omitted on macOS altogether?
TESTING (only done on *ubuntu so far)
I added debug output for the keystroke filtering, so in case something is not working as expected please run from the command line with
--developer
and share the relevant output snippets so we can debug it.Closed #8902
Footnotes
for me this didn't work when I used the fullscreen hotkey (at least in debug builds I tested so far) because the window manager (xfwm4) hotkey and the Mixxx hotkey were identical, and the keystroke was consumed by the window manager.
I have a workaround 167c569, though that's not applicable to linux distros with a global menu that require the current menubar hack, but for those hiding the menubar isn't available anyway 🤷 Maybe if my workaround is considered mergable I'll try to polish it so it replaces the hook to slotViewFullScreen on demand. ↩
I tested with Ubuntu Studio 20.04 (xfce desktop) (menus open immediately) and Ubuntu 22.04 (Gnome) (a second hotkey press is required to unroll the menu) ↩