Add 2012 to FSF copyright years for Emacs files
[bpt/emacs.git] / lisp / cus-theme.el
index 7f926c8..e662d8c 100644 (file)
@@ -1,6 +1,6 @@
 ;;; cus-theme.el -- custom theme creation user interface
 ;;
-;; Copyright (C) 2001-2011 Free Software Foundation, Inc.
+;; Copyright (C) 2001-2012 Free Software Foundation, Inc.
 ;;
 ;; Author: Alex Schroeder <alex@gnu.org>
 ;; Maintainer: FSF
@@ -157,7 +157,7 @@ remove them from your saved Custom file.\n\n"))
     ;; Load the theme settings.
     (when theme
       (unless (eq theme 'user)
-       (load-theme theme t))
+       (load-theme theme nil t))
       (dolist (setting (get theme 'theme-settings))
        (if (eq (car setting) 'theme-value)
            (progn (push (nth 1 setting) vars)
@@ -326,7 +326,7 @@ SPEC, if non-nil, should be a face spec to which to set the widget."
   (unless (eq theme 'user)
     (unless (custom-theme-name-valid-p theme)
       (error "Invalid theme name `%s'" theme))
-    (load-theme theme t))
+    (load-theme theme nil t))
   (let ((settings (reverse (get theme 'theme-settings))))
     (dolist (setting settings)
       (funcall (if (eq (car setting) 'theme-value)
@@ -521,7 +521,8 @@ It includes all faces in list FACES."
 
 (defvar custom-theme-choose-mode-map
   (let ((map (make-keymap)))
-    (set-keymap-parent map widget-keymap)
+    (set-keymap-parent map (make-composed-keymap widget-keymap
+                                                special-mode-map))
     (suppress-keymap map)
     (define-key map "\C-x\C-s" 'custom-theme-save)
     (define-key map "n" 'widget-forward)
@@ -530,7 +531,7 @@ It includes all faces in list FACES."
     map)
   "Keymap for `custom-theme-choose-mode'.")
 
-(define-derived-mode custom-theme-choose-mode nil "Themes"
+(define-derived-mode custom-theme-choose-mode special-mode "Themes"
   "Major mode for selecting Custom themes.
 Do not call this mode function yourself.  It is meant for internal use."
   (use-local-map custom-theme-choose-mode-map)