From 51594136816e52ffd27111d96463685a37b52792 Mon Sep 17 00:00:00 2001 From: William Carroll Date: Fri, 24 Dec 2021 11:47:16 -0500 Subject: fix(wpcarro/emacs): Debug vterm-mgt.el TL;DR: - vterm-mgt-repopulate-cycle -> vterm-mgt-reconcile-state - call vterm-mgt-reconcile-state everywhere to ensure state is consistent - prevent vterm from swalling EXWM KBD (C-S-f) - support vterm-mgt-select - prevent type error in cycle-append - pass t to (vterm t) to ensure it isn't a find-or-create Change-Id: I0f6d20b8d4b7533c7f56baf796ca3467a85ec770 Reviewed-on: https://cl.tvl.fyi/c/depot/+/4563 Reviewed-by: wpcarro Autosubmit: wpcarro Tested-by: BuildkiteCI --- users/wpcarro/emacs/.emacs.d/wpc/cycle.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'users/wpcarro/emacs/.emacs.d/wpc/cycle.el') diff --git a/users/wpcarro/emacs/.emacs.d/wpc/cycle.el b/users/wpcarro/emacs/.emacs.d/wpc/cycle.el index e683f3c201cf..a1853ece1431 100644 --- a/users/wpcarro/emacs/.emacs.d/wpc/cycle.el +++ b/users/wpcarro/emacs/.emacs.d/wpc/cycle.el @@ -168,7 +168,8 @@ If there is no currently focused item, add X to the beginning of XS." (if curr-i (progn (struct-set! cycle xs (-insert-at curr-i x (cycle-xs xs)) xs) - (when (>= prev-i curr-i) (struct-set! cycle previous-index (1+ prev-i) xs)) + (when (and prev-i (>= prev-i curr-i)) + (struct-set! cycle previous-index (1+ prev-i) xs)) (when curr-i (struct-set! cycle current-index (1+ curr-i) xs))) (progn (struct-set! cycle xs (cons x (cycle-xs xs)) xs) -- cgit 1.4.1