# HG changeset patch # User Kim F. Storm # Date 1164705733 0 # Node ID 9e75cb6ef88c122dc3fe31ca356caeec195a38ad # Parent b0170e860dc0c09163ce737e4fa8ee2cf32da5d1 (icomplete-tidy, icomplete-exhibit): Check that icomplete-mode is enabled. diff -r b0170e860dc0 -r 9e75cb6ef88c lisp/icomplete.el --- a/lisp/icomplete.el Tue Nov 28 09:21:58 2006 +0000 +++ b/lisp/icomplete.el Tue Nov 28 09:22:13 2006 +0000 @@ -216,7 +216,7 @@ "Remove completions display \(if any) prior to new user input. Should be run in on the minibuffer `pre-command-hook'. See `icomplete-mode' and `minibuffer-setup-hook'." - (when icomplete-eoinput + (when (and icomplete-mode icomplete-eoinput) (unless (>= icomplete-eoinput (point-max)) (let ((buffer-undo-list t)) ; prevent entry @@ -230,7 +230,7 @@ "Insert icomplete completions display. Should be run via minibuffer `post-command-hook'. See `icomplete-mode' and `minibuffer-setup-hook'." - (when (icomplete-simple-completing-p) + (when (and icomplete-mode (icomplete-simple-completing-p)) (save-excursion (goto-char (point-max)) ;; Register the end of input, so we know where the extra stuff