]> git.eshelyaron.com Git - emacs.git/commitdiff
Small codes update for revert-buffer-function no longer being nil by default
authorGlenn Morris <rgm@gnu.org>
Wed, 2 Apr 2014 07:07:11 +0000 (00:07 -0700)
committerGlenn Morris <rgm@gnu.org>
Wed, 2 Apr 2014 07:07:11 +0000 (00:07 -0700)
* lisp/menu-bar.el (menu-bar-file-menu):
* lisp/vc/ediff.el (ediff-current-file):
Update for revert-buffer-function no longer being nil by default.

lisp/ChangeLog
lisp/menu-bar.el
lisp/vc/ediff.el

index 0bfc080f8ec99b36b78653784b3f3c66d9b6fbc6..b1c35a78937fab5ac3aabd50f0ae0c200d5176a6 100644 (file)
@@ -1,5 +1,9 @@
 2014-04-02  Glenn Morris  <rgm@gnu.org>
 
+       * menu-bar.el (menu-bar-file-menu):
+       * vc/ediff.el (ediff-current-file):
+       Update for revert-buffer-function no longer being nil by default.
+
        * simple.el (command-execute): Respect nil disabled-command-function.
 
 2014-04-01  Nicolas Richard  <theonewiththeevillook@yahoo.fr>
index 0e12c976af0ec3f29e5ae65013ba428a2300b8db..84df6922749a555840d112c96503cc75e17a4342 100644 (file)
                   :help "Recover edits from a crashed session"))
     (bindings--define-key menu [revert-buffer]
       '(menu-item "Revert Buffer" revert-buffer
-                  :enable (or revert-buffer-function
-                              revert-buffer-insert-file-contents-function
+                  :enable (or (not (eq revert-buffer-function
+                                       'revert-buffer--default))
+                              (not (eq
+                                    revert-buffer-insert-file-contents-function
+                                    'revert-buffer-insert-file-contents--default-function))
                               (and buffer-file-number
                                    (or (buffer-modified-p)
                                        (not (verify-visited-file-modtime
index d8abe89d17b4401162adcc28e7687866a991170c..927a3ba7fb697d0db992e27c14ff91bdb686f0c8 100644 (file)
@@ -367,8 +367,10 @@ deleted."
 This command can be used instead of `revert-buffer'.  If there is
 nothing to revert then this command fails."
   (interactive)
-  (unless (or revert-buffer-function
-              revert-buffer-insert-file-contents-function
+  ;; This duplicates code from menu-bar.el.
+  (unless (or (not (eq revert-buffer-function 'revert-buffer--default))
+              (not (eq revert-buffer-insert-file-contents-function
+                      'revert-buffer-insert-file-contents--default-function))
               (and buffer-file-number
                    (or (buffer-modified-p)
                        (not (verify-visited-file-modtime