changeset 95843:c0e61b43cdb0

Check tool-bar-map is bound.
author Glenn Morris <rgm@gnu.org>
date Thu, 12 Jun 2008 03:57:56 +0000
parents fbeceb242efd
children 04d2abf23eda
files lisp/mh-e/mh-folder.el lisp/mh-e/mh-letter.el lisp/mh-e/mh-show.el
diffstat 3 files changed, 12 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/mh-e/mh-folder.el	Thu Jun 12 03:57:36 2008 +0000
+++ b/lisp/mh-e/mh-folder.el	Thu Jun 12 03:57:56 2008 +0000
@@ -1,6 +1,7 @@
 ;;; mh-folder.el --- MH-Folder mode
 
-;; Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+;; Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008
+;;   Free Software Foundation, Inc.
 
 ;; Author: Bill Wohler <wohler@newt.com>
 ;; Maintainer: Bill Wohler <wohler@newt.com>
@@ -590,7 +591,8 @@
   (mh-do-in-gnu-emacs
     (unless mh-folder-tool-bar-map
         (mh-tool-bar-folder-buttons-init))
-    (set (make-local-variable 'tool-bar-map) mh-folder-tool-bar-map))
+    (if (boundp 'tool-bar-map)
+        (set (make-local-variable 'tool-bar-map) mh-folder-tool-bar-map)))
   (mh-do-in-xemacs
     (mh-tool-bar-init :folder))
   (make-local-variable 'font-lock-defaults)
--- a/lisp/mh-e/mh-letter.el	Thu Jun 12 03:57:36 2008 +0000
+++ b/lisp/mh-e/mh-letter.el	Thu Jun 12 03:57:56 2008 +0000
@@ -1,7 +1,7 @@
 ;;; mh-letter.el --- MH-Letter mode
 
-;; Copyright (C) 1993, 1995, 1997,
-;;  2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+;; Copyright (C) 1993, 1995, 1997, 2000, 2001, 2002, 2003, 2004, 2005,
+;;  2006, 2007, 2008  Free Software Foundation, Inc.
 
 ;; Author: Bill Wohler <wohler@newt.com>
 ;; Maintainer: Bill Wohler <wohler@newt.com>
@@ -310,7 +310,8 @@
   (mh-do-in-gnu-emacs
     (unless mh-letter-tool-bar-map
       (mh-tool-bar-letter-buttons-init))
-    (set (make-local-variable 'tool-bar-map) mh-letter-tool-bar-map))
+    (if (boundp 'tool-bar-map)
+        (set (make-local-variable 'tool-bar-map) mh-letter-tool-bar-map)))
   (mh-do-in-xemacs
     (mh-tool-bar-init :letter))
   ;; Set the local value of mh-mail-header-separator according to what is
--- a/lisp/mh-e/mh-show.el	Thu Jun 12 03:57:36 2008 +0000
+++ b/lisp/mh-e/mh-show.el	Thu Jun 12 03:57:56 2008 +0000
@@ -1,7 +1,7 @@
 ;;; mh-show.el --- MH-Show mode
 
-;; Copyright (C) 1993, 1995, 1997,
-;;  2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+;; Copyright (C) 1993, 1995, 1997, 2000, 2001, 2002, 2003, 2004, 2005,
+;;   2006, 2007, 2008  Free Software Foundation, Inc.
 
 ;; Author: Bill Wohler <wohler@newt.com>
 ;; Maintainer: Bill Wohler <wohler@newt.com>
@@ -847,7 +847,8 @@
 
 \\{mh-show-mode-map}"
   (mh-do-in-gnu-emacs
-    (set (make-local-variable 'tool-bar-map) mh-show-tool-bar-map))
+   (if (boundp 'tool-bar-map)
+       (set (make-local-variable 'tool-bar-map) mh-show-tool-bar-map)))
   (mh-do-in-xemacs
     (mh-tool-bar-init :show))
   (set (make-local-variable 'mail-header-separator) mh-mail-header-separator)