emacs-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-commit] emacs/lisp/mh-e ChangeLog mh-utils.el


From: Peter Galbraith
Subject: [Emacs-commit] emacs/lisp/mh-e ChangeLog mh-utils.el
Date: Fri, 03 Feb 2006 20:27:35 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Branch:         
Changes by:     Peter Galbraith <address@hidden>        06/02/03 20:27:35

Modified files:
        lisp/mh-e      : ChangeLog mh-utils.el 

Log message:
        (mh-image-load-path): New variable to optionally hold the directory 
where
        MH-E images are stored.  If nil, then the function `mh-image-load-path'
        will find it.  This variable will be used for Debian packaging.
        (mh-image-load-path function): Use variable `mh-image-load-path' if
        non-nil and exists.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/emacs/emacs/lisp/mh-e/ChangeLog.diff?tr1=1.137&tr2=1.138&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/emacs/emacs/lisp/mh-e/mh-utils.el.diff?tr1=1.46&tr2=1.47&r1=text&r2=text

Patches:
Index: emacs/lisp/mh-e/ChangeLog
diff -u emacs/lisp/mh-e/ChangeLog:1.137 emacs/lisp/mh-e/ChangeLog:1.138
--- emacs/lisp/mh-e/ChangeLog:1.137     Fri Feb  3 19:32:06 2006
+++ emacs/lisp/mh-e/ChangeLog   Fri Feb  3 20:27:35 2006
@@ -1,3 +1,12 @@
+2006-02-03  Peter Galbraith  <address@hidden>
+
+       * mh-utils.el (mh-image-load-path): New variable to optionally
+       hold the directory where MH-E images are stored.  If nil, then 
+       the function `mh-image-load-path' will find it.  This variable
+       will be used for Debian packaging.
+       (mh-image-load-path function): Use variable `mh-image-load-path'
+       if non-nil and exists.
+
 2006-02-03  Mark D. Baushke  <address@hidden>
 
        * mh-tool-bar.el: Add conditional require of 'tool-bar or 'toolbar
Index: emacs/lisp/mh-e/mh-utils.el
diff -u emacs/lisp/mh-e/mh-utils.el:1.46 emacs/lisp/mh-e/mh-utils.el:1.47
--- emacs/lisp/mh-e/mh-utils.el:1.46    Wed Feb  1 23:24:34 2006
+++ emacs/lisp/mh-e/mh-utils.el Fri Feb  3 20:27:35 2006
@@ -81,6 +81,11 @@
   "Delete the next LINES lines."
   (delete-region (point) (progn (forward-line lines) (point))))
 
+(defvar mh-image-load-path nil
+  "Directory where images for MH-E are found.
+If nil, then the function mh-image-load-path will search in
+../../etc/images relative to the files in \"lisp/mh-e\".")
+
 (defvar mh-image-load-path-called-flag nil)
 
 ;;;###mh-autoload
@@ -92,14 +97,16 @@
 there. Otherwise, the images directory is added to the
 `load-path' if it isn't already there."
   (unless mh-image-load-path-called-flag
-    (let (mh-library-name mh-image-load-path)
-      ;; First, find mh-e in the load-path.
-      (setq mh-library-name (locate-library "mh-e"))
-      (if (not mh-library-name)
-        (error "Can not find MH-E in load-path"))
-      (setq mh-image-load-path
-            (expand-file-name (concat (file-name-directory mh-library-name)
-                                      "../../etc/images")))
+    (let (mh-library-name)
+      (when (or (not mh-image-load-path)
+                (not (file-exists-p mh-image-load-path)))
+        ;; First, find mh-e in the load-path.
+        (setq mh-library-name (locate-library "mh-e"))
+        (if (not mh-library-name)
+            (error "Can not find MH-E in load-path"))
+        (setq mh-image-load-path
+              (expand-file-name (concat (file-name-directory mh-library-name)
+                                        "../../etc/images"))))
       (if (not (file-exists-p mh-image-load-path))
           (error "Can not find image directory %s" mh-image-load-path))
       (if (boundp 'image-load-path)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]