emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[elpa] externals/ebdb 7721bf3 044/350: Mess with autoloads


From: Eric Abrahamsen
Subject: [elpa] externals/ebdb 7721bf3 044/350: Mess with autoloads
Date: Mon, 14 Aug 2017 11:45:59 -0400 (EDT)

branch: externals/ebdb
commit 7721bf34a4422d5c3a581dd224391cdc76695929
Author: Eric Abrahamsen <address@hidden>
Commit: Eric Abrahamsen <address@hidden>

    Mess with autoloads
    
    * ebdb.el: We were autoloading some functions that weren't actually
      being used.  Also, try out `eieio-defclass-autoload', which seems
      like it could save users some grief.
      (ebdb-db-customize): Don't require eieio-custom, function is
      autoloaded.
---
 ebdb.el | 42 ++++++++++++++++++++++++++++++++++--------
 1 file changed, 34 insertions(+), 8 deletions(-)

diff --git a/ebdb.el b/ebdb.el
index a2122fb..0a2580b 100644
--- a/ebdb.el
+++ b/ebdb.el
@@ -59,13 +59,7 @@
   (autoload 'ebdb-dwim-mail "ebdb-com")
   (autoload 'ebdb-spec-prefix "ebdb-com")
   (autoload 'ebdb-completing-read-records "ebdb-com")
-  (autoload 'mail-position-on-field "sendmail")
-  (autoload 'vm-select-folder-buffer "vm-folder")
-  (autoload 'eieio-customize-object "eieio-custom")
-  ;; cannot use autoload for variables...
-  (defvar message-mode-map) ;; message.el
-  (defvar mail-mode-map) ;; sendmail.el
-  (defvar gnus-article-buffer)) ;; gnus-art.el
+  (autoload 'eieio-customize-object "eieio-custom"))
 
 ;; These are the most important internal variables, holding EBDB's
 ;; data structures.
@@ -3007,7 +3001,6 @@ the persistent save, or allow them to propagate."
     (message "Database %s is disabled." (ebdb-string db))))
 
 (cl-defmethod ebdb-db-customize ((db ebdb-db))
-  (require 'eieio-custom)
   (eieio-customize-object db))
 
 (defun ebdb-customize-database (db)
@@ -4550,5 +4543,38 @@ but not allowing for regexps."
                        (if field (concat " with " field) "")
                        (if ebdb-search-invert "not " ""))))
 
+;; Create autoload statements for fields defined in other files.
+;; Might save users some small surprises.
+
+(eieio-defclass-autoload
+ 'gnorb-ebdb-field-messages
+ 'ebdb-field-user
+ "ebdb-gnorb"
+ "Gnorb field holding links to Gnus messages.")
+
+(eieio-defclass-autoload
+ 'gnorb-ebdb-field-tags
+ 'ebdb-field-user
+ "ebdb-gnorb"
+ "Gnorb field holding Org-style tags.")
+
+(eieio-defclass-autoload
+ 'ebdb-gnus-score-field
+ 'ebdb-field-user
+ "ebdb-gnus"
+ "Gnus field holding record score.")
+
+(eieio-defclass-autoload
+ 'ebdb-gnus-private-field
+ 'ebdb-field-user
+ "ebdb-gnus"
+ "Gnus field holding private mailbox name.")
+
+(eieio-defclass-autoload
+ 'ebdb-gnus-imap-field
+ 'ebdb-field-user
+ "ebdb-gnus"
+ "Gnus field holding private IMAP mailbox name.")
+
 (provide 'ebdb)
 ;;; ebdb.el ends here



reply via email to

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