aboutsummaryrefslogtreecommitdiff
path: root/lisp/emms-tag-editor.el
diff options
context:
space:
mode:
authorMichael Olson <mwolson@gnu.org>2008-08-08 08:59:56 -0700
committerMichael Olson <mwolson@gnu.org>2008-08-08 09:00:14 -0700
commitcf588f5ea96b7523965ac48bc39e6d9d2dc4e828 (patch)
tree8df3debe1ea84de25e0c6111a6b47e1ff59b8059 /lisp/emms-tag-editor.el
parent616f160c7f783dc232f68ea6ab8b40a36f690b18 (diff)
Introduce emms-completing-read.
This allows users to specify which completing-read function to use, defaulting to ido-completing-read. The relevant option is emms-completing-read-function. Thanks to Thierry Volpiatto for the idea.
Diffstat (limited to 'lisp/emms-tag-editor.el')
-rw-r--r--lisp/emms-tag-editor.el20
1 files changed, 11 insertions, 9 deletions
diff --git a/lisp/emms-tag-editor.el b/lisp/emms-tag-editor.el
index 5f9d78e..783abb0 100644
--- a/lisp/emms-tag-editor.el
+++ b/lisp/emms-tag-editor.el
@@ -299,8 +299,8 @@ a selected region.
If `transient-mark-mode' is on and the mark is active, the
changes will only take effect on the tracks in the region."
(interactive
- (list (completing-read "Set tag: "
- emms-tag-editor-tags nil t)
+ (list (emms-completing-read "Set tag: "
+ emms-tag-editor-tags nil t)
(read-from-minibuffer "To: ")))
(save-excursion
(save-restriction
@@ -320,8 +320,8 @@ replacement in title tags.
If `transient-mark-mode' is on and the mark is active, the
changes will only take effect on the tracks in the region."
(interactive
- (cons (completing-read "Replace in tag: "
- emms-tag-editor-tags nil t)
+ (cons (emms-completing-read "Replace in tag: "
+ emms-tag-editor-tags nil t)
(let ((common (query-replace-read-args
(if (and transient-mark-mode mark-active)
"Query replace regexp in region"
@@ -363,11 +363,13 @@ changes will only take effect on the tracks in the region."
If `transient-mark-mode' is on and the mark is active, the
changes will only take effect on the tracks in the region."
(interactive
- (let* ((tag1 (intern (completing-read "Tag 1: "
- emms-tag-editor-tags nil t)))
- (tag2 (intern (completing-read "Tag 2: "
- (assq-delete-all tag1 (copy-sequence emms-tag-editor-tags))
- nil t))))
+ (let* ((tag1 (intern (emms-completing-read "Tag 1: "
+ emms-tag-editor-tags nil t)))
+ (tag2 (intern (emms-completing-read
+ "Tag 2: "
+ (assq-delete-all tag1
+ (copy-sequence emms-tag-editor-tags))
+ nil t))))
(list tag1 tag2)))
(save-excursion
(save-restriction