-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Move global shortcut handling into OSUtils #5566
Conversation
f281b7a
to
af36eeb
Compare
faa5f46
to
4088de8
Compare
return false; | ||
} | ||
|
||
bool NixUtils::triggerGlobalShortcut(uint keycode, uint modifiers) |
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.
If this is directly a part of NixUtils, how are we handling Wayland in the future? That would be an entirely new implementation. It could make sense to add the necessary abstractions already. I believe it should also be possible to build without X11 headers present on the system.
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.
Perhaps we need an X11Utils and WaylandUtils. I did move some of the X11 quirks into a separate cpp.
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.
I'd rather think we need to add another abstraction layer there. As I see it, NixUtils will grow with additional features that are specific to certain DEs and we don't want to duplicate all that unnecessarily.
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.
I also think that the possibility to handle features specific to DEs is necessary. And FYI what a DE-specific implementation looks like: I tried to implement auto-type on KDE Wayland a while ago.
4088de8
to
28f4eac
Compare
* Add shortcut error handling and duplicate shortcut detection * Improve linux build settings to prevent issues with PIC and PIE protections
28f4eac
to
28cf6e0
Compare
After 404fd94 ("Move global shortcut handling into OSUtils (keepassxreboot#5566)"), X11Extras was made mandatory, even though it is only used for autotype. Make it conditional on autotype again.
Complete overhaul of global shortcut handling. Removed all shortcut handling from Auto-Type classes into OSUtils. Enabled by-name referencing of global shortcuts.
Performed cleanup of X11 functions in Linux Auto-Type.
This is prep work to adding multiple global shortcuts including "Show KeePassXC" and "Auto-Type Password Only".
TODO:
Testing strategy
Tested functionality in Windows, Linux, and macOS. Minimal changes to unit tests!
Type of change