Skip to content

Commit

Permalink
Add keybindings to test suspending groups
Browse files Browse the repository at this point in the history
  • Loading branch information
sdilts committed Feb 2, 2025
1 parent 418a271 commit 763c8a0
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion lisp/key-bindings.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,16 @@
(let ((group (mahogany-current-group *compositor-state*)))
(group-prev-frame group seat)))

(defun suspend-group (sequence seat)
(declare (ignore sequence seat))
(let ((group (mahogany-current-group *compositor-state*)))
(group-suspend group seat)))

(defun wakeup-group (sequence seat)
(declare (ignore sequence seat))
(let ((group (mahogany-current-group *compositor-state*)))
(group-wakeup group seat)))

(setf (mahogany-state-keybindings *compositor-state*)
(list (define-kmap
(kbd "C-t") (define-kmap
Expand All @@ -63,4 +73,7 @@
(kbd "Q") #'maximize-current-frame
(kbd "n") #'next-view
(kbd "p") #'previous-view
(kbd "+") #'open-kcalc))))
(kbd "+") #'open-kcalc
(kbd "g") (define-kmap
(kbd "s") #'suspend-group
(kbd "w") #'wakeup-group)))))

0 comments on commit 763c8a0

Please sign in to comment.