commit-womb
[Top][All Lists]
Advanced

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

[Commit-womb] addressbook ChangeLog addressbook.el


From: Jose E. Marchesi
Subject: [Commit-womb] addressbook ChangeLog addressbook.el
Date: Sat, 05 May 2007 23:45:43 +0000

CVSROOT:        /cvsroot/womb
Module name:    addressbook
Changes by:     Jose E. Marchesi <jemarch>      07/05/05 23:45:43

Modified files:
        .              : ChangeLog addressbook.el 

Log message:
        patches from Xavier Maillard

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/addressbook/ChangeLog?cvsroot=womb&r1=1.4&r2=1.5
http://cvs.savannah.gnu.org/viewcvs/addressbook/addressbook.el?cvsroot=womb&r1=1.3&r2=1.4

Patches:
Index: ChangeLog
===================================================================
RCS file: /cvsroot/womb/addressbook/ChangeLog,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -b -r1.4 -r1.5
--- ChangeLog   5 May 2007 19:47:46 -0000       1.4
+++ ChangeLog   5 May 2007 23:45:42 -0000       1.5
@@ -1,3 +1,10 @@
+2007-05-05  Xavier Maillard  <address@hidden>
+
+       * addressbook.el: Do not require 'cl at run-time.
+       (addrbook-mode-line-string, addrbook-summary-mode-line-string):
+       New variables. Use them in *-set-mode-line (still needs attention).
+       (addressbook-summary): Fixed autoload cookie.
+
 2007-05-05  Jose E. Marchesi  <address@hidden>
 
        * addressbook.el (addrbook-open): New function.

Index: addressbook.el
===================================================================
RCS file: /cvsroot/womb/addressbook/addressbook.el,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -b -r1.3 -r1.4
--- addressbook.el      5 May 2007 19:47:46 -0000       1.3
+++ addressbook.el      5 May 2007 23:45:42 -0000       1.4
@@ -5,7 +5,7 @@
 ;; Maintainer: Jose E. Marchesi
 ;; Keywords: contacts, applications
 
-;; $Id: addressbook.el,v 1.3 2007/05/05 19:47:46 jemarch Exp $
+;; $Id: addressbook.el,v 1.4 2007/05/05 23:45:42 jemarch Exp $
 
 ;; This file is NOT part of GNU Emacs.
 
@@ -30,7 +30,7 @@
 
 ;;; Code:
 
-(require 'cl)
+(eval-when-compile (require 'cl))
 (require 'vcard)
 (require 'url)
 (require 'mm-decode)
@@ -216,6 +216,7 @@
     ("avi" nil)
     ("qtime" nil))
   "Association between vCard image types and emacs image types")
+
 (defvar addrbook-cards nil
   "Cards of the current addressbook")
 
@@ -394,6 +395,14 @@
 (defvar addrbook-summary-buffer nil
   "Actual summary buffer")
 
+(defvar addrbook-mode-line-string " AddressBook"
+  "String to display on the mode line when in the addressbook mode.
+If `nil', do not show anything.")
+
+(defvar addrbook-summary-mode-line-string " AddressBook Sum"
+  "String to display on the mode line when in the addressbook summary mode.
+If `nil', do not show anything.")
+
 ;;;; Managing properties group data
 
 ;;; Groups
@@ -567,7 +576,7 @@
     (when (and with-aka name-aka-p)
       (setq result (concat result
                            (when (or name-prefix-p
-                                     name-fist-name-p
+                                     name-first-name-p
                                      name-surname-p
                                      name-suffix-p) " ")
                            "(" name-aka ")")))
@@ -1471,23 +1480,27 @@
 
 ;;;; Modeline
 
+;;; FIXME: this is ugly
 (defun addrbook-set-mode-line (card-number total-cards)
   "Update the modeline of the current buffer"
+  (when addrbook-mode-line-string
   (setq mode-line-buffer-identification
         (list 24
-              "AddressBook"
+              addrbook-mode-line-string
               ": "
               (list 10 
-                    (format "%d/%d" card-number total-cards)))))
+                    (format "%d/%d" card-number total-cards))))))
 
+;;; FIXME: this is ugly
 (defun addrbook-summary-set-mode-line (card-number total-cards)
   "Update the mdoeline of the current summary buffer"
+  (when addrbook-summary-mode-line-string
   (setq mode-line-buffer-identification
         (list 24
-              "AddressBook Summary"
+               addrbook-summary-mode-line-string
               ": "
               (list 10 
-                    (format "%d/%d" card-number total-cards)))))
+                     (format "%d/%d" card-number total-cards))))))
             
 ;;;; Group/Attribute fast selection
 ;;; Adapted from `org-fast-tag-selection' in org.el by Carsten Dominic
@@ -1783,7 +1796,7 @@
     (if new-card-index
         (addrbook-save-cards nil))))
 
-;;;##autoload
+;;;###autoload
 (defun addressbook-summary ()
   "Open the addressbook and show the summary window"
   (interactive)




reply via email to

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