all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* `ido.el' small, but annoying bug
@ 2004-12-03 18:05 Paul Pogonyshev
  2004-12-04  0:51 ` Kim F. Storm
  0 siblings, 1 reply; 7+ messages in thread
From: Paul Pogonyshev @ 2004-12-03 18:05 UTC (permalink / raw)
  Cc: Kim F. Storm

Type `C-x b', use left/right arrow to select a different buffer
and then `C-k' to kill it.  With my Emacs (a recent CVS) the
list of buffers disappears, but can be reshown again by e.g.
pressing left/right arrow.

The following smallish patch seems to fix it.  However, `ido.el'
maintainer should certainly review it.


2004-12-03  Paul Pogonyshev  <pogonyshev@gmx.net>

	* ido.el (ido-matches): Doc fix.
	(ido-kill-buffer-at-head): Remove the killed buffer from
	`ido-matches' in addition to `ido-cur-list'.
	(ido-delete-file-at-head): Likewise for deleted file.


--- ido.el	24 Nov 2004 21:52:11 +0200	1.45
+++ ido.el	03 Dec 2004 19:59:32 +0200	
@@ -917,7 +917,7 @@ Copied from `icomplete-eoinput'.")
   "The initial string for the users string it is typed in.")
 
 (defvar ido-matches nil
-  "List of files currently matching `ido-text'.")
+  "List of files or buffers currently matching `ido-text'.")
 
 (defvar ido-report-no-match t
   "Report [No Match] when no completions matches ido-text.")
@@ -3218,7 +3218,8 @@ for first matching file."
 	  ;; buffer couldn't be killed.
 	  (setq ido-rescan t)
 	;; else buffer was killed so remove name from list.
-	(setq ido-cur-list (delq buf ido-cur-list))))))
+	(setq ido-cur-list (delq buf ido-cur-list)
+	      ido-matches  (delq buf ido-matches))))))
 
 ;;; DELETE CURRENT FILE
 (defun ido-delete-file-at-head ()
@@ -3239,7 +3240,8 @@ for first matching file."
 	  ;; file could not be deleted
 	  (setq ido-rescan t)
 	;; else file was killed so remove name from list.
-	(setq ido-cur-list (delq (car ido-matches) ido-cur-list))))))
+	(setq ido-cur-list (delq (car ido-matches) ido-cur-list)
+	      ido-matches  (cdr ido-matches))))))
 
 
 ;;; VISIT CHOSEN BUFFER

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2004-12-06 17:49 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-12-03 18:05 `ido.el' small, but annoying bug Paul Pogonyshev
2004-12-04  0:51 ` Kim F. Storm
2004-12-04  1:13   ` Paul Pogonyshev
2004-12-04 18:31   ` Paul Pogonyshev
2004-12-06 13:15     ` Kim F. Storm
2004-12-06 16:25       ` Urban Engberg
2004-12-06 17:49         ` Paul Pogonyshev

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.