summaryrefslogtreecommitdiff
path: root/src/managers/KeybindManager.cpp
Commit message (Collapse)AuthorAgeFilesLines
* core: fix on-empty workspace being called too often (#6026)Brenno Lemos2024-05-121-2/+2
|
* keybinds: fix release binds in submaps (#6025)shezdy2024-05-121-3/+2
|
* core: remove unused includes and fix warnVaxry2024-05-101-2/+0
|
* keybinds: Fix classic global keybinds(pass dispatcher) (#5967)sub-kek2024-05-091-1/+1
|
* cursor: move to a hyprland implVaxry2024-05-091-23/+22
| | | | | | | This moves wlr_cursor to a completely new impl mostly under CPointerManager Also adds beginSimple to OpenGL for simple render passes (e.g. cursor)
* ipc: add togglegroup, moveintogroup and moveoutofgroup events (#5866)VPavliashvili2024-05-071-0/+4
|
* keybinds: fix xkb keybind name to keysym comparison (#5917)Ikalco2024-05-071-5/+4
|
* keybinds: make the keybind manager check for session lock (#5894)Ikalco2024-05-051-0/+3
|
* internal: new shared_ptr and weak_ptr implementation (#5883)Vaxry2024-05-051-14/+14
| | | | | | | | | | | moves std::shared_ptrs to a new implementation Advantages: - you can dereference a weak_ptr directly. This will obviously segfault on a nullptr deref if it's expired. - this is useful to avoid the .lock() hell where we are 100% sure the pointer _should_ be valid. (and if it isn't, it should throw.) - weak_ptrs are still valid while the SP is being destroyed. - reasoning: while an object (e.g. CWindow) is being destroyed, its `weak_ptr self` should be accessible (the sp is still alive, and so is CWindow), but it's not because by stl it's already expired (to prevent resurrection) - this impl solves it differently. w_p is expired, but can still be dereferenced and used. Creating `s_p`s is not possible anymore, though. - this is useful in destructors and callbacks.
* input: Introduce basic hyprland HID classesVaxry2024-05-031-15/+16
| | | | | | Implements an intermediary HID class for mice, keyboards and touch devices, removing the old structs from WLClasses.hpp Yes, virtual ones are duplicated a bit, but will likely be de-duped once wlr_input_device is not used anymore.
* inputmgr: dont double free on hotplug (#5855)Tom Englund2024-05-031-1/+0
| | | | | | | | | | | | | | * inputmgr: dont double free on hotplug since we are also unrefing the state on hotplugging the keyboard set the state to nullptr so the destructor if case actually catches its been already freed. * keybindgmgr: dont double free on layout switching d5bf153 added keymap unref at the end of updateXKBTranslationState to not leak it when exiting, only it causes updateXKBTranslationState to double free when changing layouts. since its already freed. remove the unneeded extra xkb_keymap_unref.
* internal: fix a few asan reported leaks on exit of hyprland (#5852)Tom Englund2024-05-031-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | * notifications: free cairo images on destruction asan reports a leak on exit if we dont free the image we created in the draw function. add a destructor and free images on exit. * compositor: destroy wlroots types on exit there are a few types not being destroyed on exit and causing a leak on exit in wlroots reported by asan, add those. * cursormgr: ensure we destroy cursor mgr on exit add a destructor and call wlr_xcursor_manager_destroy on the manager on destruction, leak reported by asan. * keybindmgr: free state and keymap add missing keymap_unref on creation, and add a destructor and free the state on exit. leak reported by asan. * skeyboard: add destructor and free state free the state on destruction of keyboard, reported as leak by asan
* ime-v2: move to new implVaxry2024-05-011-3/+0
|
* keybinds: check for special workspace equality before switchingVaxry2024-04-301-1/+2
| | | | fixes #5814
* wlr-output-power: move to new implVaxry2024-04-291-0/+2
|
* internal: Window storage rework - part 1 (#5762)Vaxry2024-04-271-104/+110
| | | | | | | | | | | | | | | | | * Window storage rework - part 1 * format * remove useless include * fix pch * format * fix crash in dwindle * fix vram leak * prefer .expired() for bool checks
* shortcuts-inhibitor: move to new implVaxry2024-04-251-7/+4
|
* tokens: add more modes to initial_workspace_trackingVaxry2024-04-241-2/+3
| | | | | | 1 is single-shot, 2 is persistent fixes #5732
* tokens: fix initial workspace token ignoring specialVaxry2024-04-241-1/+4
| | | | ref #5726
* windows: add misc:initial_workspace_trackingVaxry2024-04-231-1/+25
| | | | | | By default enabled, will track the initial opened workspace of a window spawned for 2 minutes or until it's moved to a different workspace. For example: you run a launcher and open an app on workspace 1, but quickly switch to workspace 2. The app will now open on workspace 1 regardless of your switch.
* keybinds: clear repeat source on mouse inputsVaxry2024-04-211-12/+18
| | | | fixes #5671
* HookSystem: improve callback safetyVaxry2024-04-201-1/+1
|
* windows: recalculate monitor after updating windows (#5647)Sungyoon Cho2024-04-191-0/+2
| | | | Recalculate monitor after updating windows, so layout render doesn't get overridden.
* keybindmgr: add optional `silent` suffix to `movewindow`. (#5597)Maarten de Vries2024-04-171-7/+15
| | | | | | With the `silent` suffix, the focus remains on the current position in the layout or the current monitor, instead of following the moved window. When combined with `movewindow mon:X`, this this allows you to get the same behavior as xmonad's `windowToScreen` command.
* keybindmgr: fix workspace_back_and_forth (#5585)go0d1uck2024-04-141-1/+1
|
* workspace: update windows when selector match could change (#5533)Sungyoon Cho2024-04-101-9/+10
| | | | | | | * workspace: update windows when group updates * workspace: update windows when floating toggle * workspace: update windows when stop dragging window by mouse
* keybinds: fix spammy warningVaxry2024-04-041-13/+13
|
* Workspace/core: Refactor workspace storage (#5380)Vaxry2024-04-021-31/+31
| | | | | * refactor workspaces to use ptrs * clang-format
* dispatchers: open special ws on active monitor instead of mouse monitor (#5330)thejch2024-03-301-4/+1
|
* keybinds: add binds:disable_keybind_grabbingVaxry2024-03-291-1/+3
| | | | fixes #5273
* keybinds: Fix exit trigger by moving it to monitor.frame (#5240)dmayle2024-03-251-1/+1
|
* config/workspace: added workspace selectorsVaxry2024-03-191-1/+3
|
* socket2: add pin eventVaxry2024-03-181-0/+3
| | | | fixes #4778
* keybinds: add Dispatchers for "force float" and "force tiling" (non-toggle) ↵djvs2024-03-171-1/+18
| | | | | | | | | (#5137) --------- Co-authored-by: djvs <djvs@users.noreply.github.com>
* master: Fix master layout window focus and scroll (#5074)thejch2024-03-131-1/+5
| | | | | | | | | | | * fix master switch window scrolling * fix some more dispatchers and remove some duplicate code * refactor and remove duplicate code * fix focusmonitor: https://github.com/hyprwm/Hyprland/issues/5006#issuecomment-1986977255 * change check
* keybinds: Fix typo (#5081)Ikko Eltociear Ashimine2024-03-121-1/+1
| | | minor fix
* core: Fix typo and check grandchild PID in spawn() (#5070)Lucas Reis2024-03-111-2/+2
|
* deps: update wlrootsVaxry2024-03-091-8/+8
|
* keybinds: track submap at press for keypressesVaxry2024-03-091-1/+3
| | | | fixes #5037
* keybinds: Allow fullscreen/maximize in special workspace (#4921)thejch2024-03-041-3/+0
| | | | | | | | | | | | | | | * allow fullscreen/maximize in special workspace * remove duplicate code * hide top layer * fix special fullscreen deco * edit * fix fade top layer when toggle special * remove double render
* keybinds: Better handling of workspace_back_and_forth (#4952)Tom Benham2024-03-041-11/+24
| | | | | | | | | | | * Removed redundant boolean condition * Better handling of workspace_back_and_forth when using focusworkspaceoncurrentmonitor dispatcher * Fixed config acquisition --------- Co-authored-by: Tom Benham <tom.benham@quadrille.fr>
* config: improve config value infrastructureVaxry2024-03-031-62/+63
|
* keybinds: Add the 'catchall' keyword that matches all keys (#4930)Tobias Zimmermann2024-03-031-11/+5
| | | | | | | | | | | | | | | | * Add the 'catchall' keyword that matches all keys This keyword can be used to define arbitrary keybinds. The only special behavior that it exhibits is that it matches every key, including modifier keys. Any flags still apply normally. This commit also fixes an issue that keys bound via the code:KEYCODE format were not unbound correctly. * Disallow catchall keybinds outside of submaps A catchall keybind outside a submap would prevent essentially all key events from going through to applications and would be difficult to remove again.
* animations: Refactor AnimatedVariable (#4911)GartoxFR2024-03-021-26/+26
| | | | | | | | | | | | | | | | | | | | | | | * animation: Refactor AnimatedVariable This commit decomposes the AnimatedVariable class into a base class with the common attribute to all variable types and a templated derived type containing strongly typed info on the type being animated. Access to the typed version is perfomed using the visitor pattern. A utility is provided to build a visitor on the fly using lambdas. Adding a new type to be animated should just be a matter of adding the typed in the list defined by the ANIMABLE_TYPES macro The size of the commit is justified by the API change in the AnimatedVariable class. No more vec(), fl() or col() method but a unified value() method. * animation: Remove visitor pattern * animation: Fix coding style * animation: Fix coding style
* keybinds: unconstrain mouse on focusmonitor and cyclenext (#4863)JManch2024-02-281-9/+4
|
* config: Add option to resolve keybinds by sym instead of code (#4851)Tobias Zimmermann2024-02-271-1/+1
| | | | | | | | | | | | | | This commit adds the new configuration option 'resolve_binds_by_sym' which can be set globally or per-device. It is off by default, which preserves the current behavior. This setting only affects the behavior of keybinds that are defined via key symbols, not those defined via keycode. Binds defined by symbols currently activate if the keycode pressed would generate the specified symbol on the first layout specified in the input section. If enabled, keys pressed on the relevant device will instead match keybinds by the symbols they produce with their current layout. Closes #1881.
* wayland: implement keyboard_shortcuts_inhibit_v1Vaxry2024-02-271-0/+9
| | | | fixes #4568
* input: Map touch devices and tablets bound to an output (#3544)Philip Damianik2024-02-271-1/+1
| | | | | | | | | | | * Map bound touch devices and tablets to an output * Add "[[Auto]]" default option for auto detecting outputs for touch inputs * Bind new monitors to configured touch and tablet devices * Use Monitor::matchesStaticSelector in CConfigManager::getMonitorRuleFor * Use Monitor::matchesStaticSelector in CCompositor::getMonitorFromString
* keybinds: fix movewindoworgroup onto empy workspace on next monitor (#4486)Bernd Müller2024-02-261-1/+5
| | | | | | | | | * fix: movewindoworgroup when no window or group is in desired direction, e.g. move window onto empty workspace on next monitor * fix: movewindoworgroup when no window or group is in desired direction, e.g. move window onto empty workspace on next monitor * reset flake.nix * add: changes mentioned in review of #4486
* keybinds: focus floating on top of fsVaxry2024-02-261-7/+16
|