]> git.eshelyaron.com Git - emacs.git/commitdiff
Simplify unloading functions after 2011-06-25T17:42:18Z!lekktu@gmail.com.
authorJuanma Barranquero <lekktu@gmail.com>
Sat, 25 Jun 2011 18:08:41 +0000 (20:08 +0200)
committerJuanma Barranquero <lekktu@gmail.com>
Sat, 25 Jun 2011 18:08:41 +0000 (20:08 +0200)
* allout.el (allout-unload-function): Pass -1 to `allout-mode'.

* proced.el (proced-unload-function):
* progmodes/cperl-mode.el (cperl-mode-unload-function): Remove.

* ses.el (ses-unload-function):
* emacs-lisp/re-builder.el (re-builder-unload-function): Simplify.

lisp/ChangeLog
lisp/allout.el
lisp/emacs-lisp/re-builder.el
lisp/proced.el
lisp/progmodes/cperl-mode.el
lisp/ses.el

index bccbe9340b1b1560822ba318745dd0d0b4fa85e1..39a428a5a28094f61b1fbab7595bea7c9632a27e 100644 (file)
@@ -1,3 +1,13 @@
+2011-06-25  Juanma Barranquero  <lekktu@gmail.com>
+
+       * allout.el (allout-unload-function): Pass -1 to `allout-mode'.
+
+       * ses.el (ses-unload-function):
+       * emacs-lisp/re-builder.el (re-builder-unload-function): Simplify.
+
+       * proced.el (proced-unload-function):
+       * progmodes/cperl-mode.el (cperl-mode-unload-function): Remove.
+
 2011-06-25  Andreas Rottmann  <a.rottmann@gmx.at>
 
        * server.el (server-create-window-system-frame): Add parameters arg.
index 8cdf24176b0af4460b9c7a886337c8c544e780b4..1d4d4a20e119b27ccfd4b8d3b893c4a8d3bd5432 100644 (file)
@@ -2085,7 +2085,7 @@ OPEN:     A TOPIC that is not CLOSED, though its OFFSPRING or BODY may be."
   (save-current-buffer
     (dolist (buffer (buffer-list))
       (set-buffer buffer)
-      (when (allout-mode-p) (allout-mode))))
+      (when (allout-mode-p) (allout-mode -1))))
   ;; continue standard unloading
   nil)
 
index 5ce18d020c96abfe05f7b7f2d95403366d5ced1c..ebbd6ff1fdff84106724a3b8b22ff21038cf4137 100644 (file)
@@ -714,8 +714,7 @@ If SUBEXP is non-nil mark only the corresponding sub-expressions."
       (remove-hook 'after-change-functions 'reb-auto-update t)
       (remove-hook 'kill-buffer-hook 'reb-kill-buffer t)
       (when (reb-mode-buffer-p)
-       (reb-delete-overlays)
-       (funcall (or (default-value 'major-mode) 'fundamental-mode)))))
+       (reb-delete-overlays))))
   ;; continue standard unloading
   nil)
 
index 4436129ce1607300a4f3279684aca71dacd8fd48..11598d7350f6d31f8eb3ae0305fdd628d0a96319 100644 (file)
@@ -1869,16 +1869,6 @@ buffer.  You can use it to recover marks."
   (message "Change in Proced buffer undone.
 Killed processes cannot be recovered by Emacs."))
 
-(defun proced-unload-function ()
-  "Unload the Proced library."
-  (save-current-buffer
-    (dolist (buf (buffer-list))
-      (set-buffer buf)
-      (when (eq major-mode 'proced-mode)
-        (funcall (or (default-value 'major-mode) 'fundamental-mode)))))
-  ;; continue standard unloading
-  nil)
-
 (provide 'proced)
 
 ;;; proced.el ends here
index 2cce5e13fb0092a7c4eaef0e75fa16b339d13291..8eb2d01c0972e5b3a022db65c8b93ea9b124829e 100644 (file)
@@ -8971,18 +8971,6 @@ do extra unwind via `cperl-unwind-to-safe'."
     (substring v (match-beginning 1) (match-end 1)))
   "Version of IZ-supported CPerl package this file is based on.")
 
-(defun cperl-mode-unload-function ()
-  "Unload the Cperl mode library."
-  (let ((new-mode (if (eq (symbol-function 'perl-mode) 'cperl-mode)
-                     'fundamental-mode
-                   'perl-mode)))
-    (dolist (buf (buffer-list))
-      (with-current-buffer buf
-       (when (eq major-mode 'cperl-mode)
-         (funcall new-mode)))))
-  ;; continue standard unloading
-  nil)
-
 (provide 'cperl-mode)
 
 ;;; cperl-mode.el ends here
index 2fc85d27df90faa021ce1766032081c7918900d5..b52d3e23c736897c3e33412cc5945c5c0f1c50eb 100644 (file)
@@ -3006,11 +3006,6 @@ current column and continues until the next nonblank column."
   (dolist (fun '(copy-region-as-kill yank))
     (ad-remove-advice fun 'around (intern (concat "ses-" (symbol-name fun))))
     (ad-update fun))
-  (save-current-buffer
-    (dolist (buf (buffer-list))
-      (set-buffer buf)
-      (when (eq major-mode 'ses-mode)
-       (funcall (or (default-value 'major-mode) 'fundamental-mode)))))
   ;; continue standard unloading
   nil)