-
Notifications
You must be signed in to change notification settings - Fork 5
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
Open settings with a long press on the Menu key #179
Conversation
It shows unavailable options, for example Show Sources. As for back and reload actions, the interface should already provide those actions.
Window was not shown in this context. And we have to provide a size, otherwise on my WM (labwc), the window is very small.
Not sure I understand the problem yet, but maybe detect and ignore auto repeats? https://doc.qt.io/qt-5/qkeyevent.html#isAutoRepeat |
Use auto repeat to prevent re-triggering toggling the settings more than once when very long pressing the Menu key.
Good idea, this fixes it: 891c1d5 |
This change brings another side-effect: When pressing Ctrl-C in the terminal from which I launched the kiosk browser, I now get what looks like a crash.
Previously the Ctrl-C was ignored. |
We could continue to ignore Ctrl-C, which can be done with: # Prevent closing the Kiosk with SIGINT https://stackoverflow.com/a/842807
signal.signal(signal.SIGINT, signal.SIG_IGN) |
I think we could also change it to exiting, but gracefully instead of crashing. |
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
⚡
Demo
2024-09-24_10-55-16.mp4
Using https://github.com/dividat/diviapps/pull/2161 locally, pressing the Menu key with a short press first, and then pressing the Menu key with a long press.
Limitations
Fixed by 891c1d5.
Keeping the long press longer after the settings have been shown, it will trigger again after the delay the settings toggle. For some reason, we get a release signal, followed by a Press signal, after we toggle the settings.
2024-09-24_10-55-59.mp4
Checklist