Procházet zdrojové kódy

Bugfix: don't ignore case when building the list of targets.

If you have a TODO keyword like "DELEGATED" and an entry like
"* Delegated this stuff to X", then you want this entry to be
in the list of possible targets.  For that we need to distinguish
between DELEGATED as a keyword and "Delegated" as a simple word,
so (case-fold-search nil) seems relevant.
Bastien Guerry před 15 roky
rodič
revize
57b43866e5
2 změnil soubory, kde provedl 6 přidání a 1 odebrání
  1. 3 0
      lisp/ChangeLog
  2. 3 1
      lisp/org.el

+ 3 - 0
lisp/ChangeLog

@@ -1,5 +1,8 @@
 2009-07-18  Bastien Guerry  <bzg@altern.org>
 
+	* org.el (org-get-refile-targets): Fix bug: don't ignore case when
+	building the list of targets.
+
 	* org-remember.el (org-remember-delete-empty-lines-at-end): New
 	option.
 	(org-remember-handler): Use the new option.

+ 3 - 1
lisp/org.el

@@ -8283,7 +8283,9 @@ on the system \"/user@host:\"."
 
 (defun org-get-refile-targets (&optional default-buffer)
   "Produce a table with refile targets."
-  (let ((entries (or org-refile-targets '((nil . (:level . 1)))))
+  (let ((case-fold-search nil)
+	;; otherwise org confuses "TODO" as a kw and "Todo" as a word
+	(entries (or org-refile-targets '((nil . (:level . 1)))))
 	targets txt re files f desc descre fast-path-p level pos0)
     (message "Getting targets...")
     (with-current-buffer (or default-buffer (current-buffer))