|
@@ -52,7 +52,13 @@ not be updated until you restart Emacs.")
|
|
|
|
|
|
;;; Debug messages
|
|
|
|
|
|
-(defvar ido-cr+-debug-mode)
|
|
|
+(define-minor-mode ido-cr+-debug-mode
|
|
|
+ "If non-nil, ido-cr+ will print debug info.
|
|
|
+
|
|
|
+Debug info is printed to the *Messages* buffer."
|
|
|
+ nil
|
|
|
+ :global t
|
|
|
+ :group 'ido-completing-read-plus)
|
|
|
|
|
|
;; Defined as a macro for efficiency (args are not evaluated unless
|
|
|
;; debug mode is on)
|
|
@@ -285,29 +291,17 @@ sets up C-j to be equivalent to TAB in the same situation."
|
|
|
;; Only if using ico-cr+
|
|
|
ido-cr+-enable-this-call
|
|
|
;; Only if require-match is non-nil
|
|
|
- ido-require-match
|
|
|
+ (with-no-warnings ido-require-match)
|
|
|
;; Only if current text is non-empty
|
|
|
(not (string= ido-text ""))
|
|
|
;; Only if current text is not a complete choice
|
|
|
- (not (member ido-text ido-cur-list)))
|
|
|
+ (not (member ido-text (with-no-warnings ido-cur-list))))
|
|
|
(progn
|
|
|
(ido-cr+--debug-message
|
|
|
"Overriding C-j behavior for require-match: performing completion instead of exiting.")
|
|
|
(ido-complete))
|
|
|
ad-do-it))
|
|
|
|
|
|
-;;; Debug mode
|
|
|
-
|
|
|
-;; This is defined at the end so it goes at the bottom of the
|
|
|
-;; customization group
|
|
|
-(define-minor-mode ido-cr+-debug-mode
|
|
|
- "If non-nil, ido-cr+ will print debug info.
|
|
|
-
|
|
|
-Debug info is printed to the *Messages* buffer."
|
|
|
- nil
|
|
|
- :global t
|
|
|
- :group 'ido-completing-read-plus)
|
|
|
-
|
|
|
(provide 'ido-completing-read+)
|
|
|
|
|
|
;;; ido-completing-read+.el ends here
|