org-export: uniquify and sort allowed keys in dispatcher expert UI

* contrib/lisp/org-export.el (org-export-dispatch-ui): uniquify and
  sort allowed keys.
This commit is contained in:
Nicolas Goaziou 2012-11-22 15:32:01 +01:00
parent 785e470c6c
commit 68234d5a41
1 changed files with 2 additions and 2 deletions

View File

@ -4857,9 +4857,9 @@ back to standard interface."
;; always available.
(allowed-keys
(nconc (list ?1 ?2 ?3 ?4)
(if (not first-key) (mapcar 'car backends)
(if (not first-key) (org-uniquify (mapcar 'car backends))
(let (sub-menu)
(dolist (backend backends (mapcar 'car sub-menu))
(dolist (backend backends (sort (mapcar 'car sub-menu) '<))
(when (eq (car backend) first-key)
(setq sub-menu (append (nth 2 backend) sub-menu))))))
(cond ((eq first-key ?P) (list ?f ?p ?x ?a))