app/irc: fix +irc/ivy-jump-to-channel
not it works when buffer-names are indented below server
This commit is contained in:
parent
b002883d40
commit
360eef0602
1 changed files with 8 additions and 1 deletions
|
@ -62,7 +62,14 @@ argument) is non-nil only show channels in current server."
|
|||
(cl-loop for buf in (circe-server-chat-buffers)
|
||||
unless (eq buf current-buffer)
|
||||
collect (format " %s" (buffer-name buf)))))
|
||||
:action #'ivy--switch-buffer-action
|
||||
:action #'+irc--ivy-switch-to-buffer-action
|
||||
:preselect (buffer-name (current-buffer))
|
||||
:keymap ivy-switch-buffer-map
|
||||
:caller '+irc/ivy-jump-to-channel)))
|
||||
|
||||
;;;###autoload
|
||||
(defun +irc--ivy-switch-to-buffer-action (buffer)
|
||||
(when (stringp buffer)
|
||||
(if (get-buffer buffer)
|
||||
(ivy--switch-buffer-action buffer)
|
||||
(ivy--switch-buffer-action (s-trim-left buffer)))))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue