Check whether there's a prev/next window config to switch to
Closes #111
This commit is contained in:
@ -405,7 +405,7 @@ window config COUNT."
|
|||||||
(index (-elem-index match window-configs)))
|
(index (-elem-index match window-configs)))
|
||||||
(if count
|
(if count
|
||||||
(eyebrowse-switch-to-window-config count)
|
(eyebrowse-switch-to-window-config count)
|
||||||
(when index
|
(when (and index (> (length window-configs) 1))
|
||||||
(if (< (1+ index) (length window-configs))
|
(if (< (1+ index) (length window-configs))
|
||||||
(eyebrowse-switch-to-window-config
|
(eyebrowse-switch-to-window-config
|
||||||
(car (nth (1+ index) window-configs)))
|
(car (nth (1+ index) window-configs)))
|
||||||
@ -427,7 +427,7 @@ switch COUNT window configs backwards and always wrap around."
|
|||||||
(eyebrowse-prev-window-config
|
(eyebrowse-prev-window-config
|
||||||
(when (> count 1)
|
(when (> count 1)
|
||||||
(eyebrowse-prev-window-config (1- count)))))
|
(eyebrowse-prev-window-config (1- count)))))
|
||||||
(when index
|
(when (and index (> (length window-configs) 1))
|
||||||
(if (> index 0)
|
(if (> index 0)
|
||||||
(eyebrowse-switch-to-window-config
|
(eyebrowse-switch-to-window-config
|
||||||
(car (nth (1- index) window-configs)))
|
(car (nth (1- index) window-configs)))
|
||||||
|
|||||||
Reference in New Issue
Block a user