emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] Changes to emacs/lisp/uniquify.el


From: Stefan Monnier
Subject: [Emacs-diffs] Changes to emacs/lisp/uniquify.el
Date: Thu, 27 Jun 2002 11:35:48 -0400

Index: emacs/lisp/uniquify.el
diff -c emacs/lisp/uniquify.el:1.35 emacs/lisp/uniquify.el:1.36
*** emacs/lisp/uniquify.el:1.35 Sat May 18 22:11:03 2002
--- emacs/lisp/uniquify.el      Thu Jun 27 11:35:48 2002
***************
*** 385,405 ****
  ;; (This ought to set some global variables so the work is done only for
  ;; buffers with names similar to the deleted buffer.  -MDE)
  
! (defun delay-uniquify-rationalize-file-buffer-names ()
    "Add `delayed-uniquify-rationalize-file-buffer-names' to 
`post-command-hook'.
  For use on, eg, `kill-buffer-hook', to rationalize *after* buffer deletion."
    (if (and uniquify-buffer-name-style
!          uniquify-after-kill-buffer-p)
        (add-hook 'post-command-hook
!               'delayed-uniquify-rationalize-file-buffer-names)))
  
! (defun delayed-uniquify-rationalize-file-buffer-names ()
    "Rerationalize buffer names and remove self from `post-command-hook'.
  See also `delay-rationalize-file-buffer-names' for hook setter."
    (uniquify-rationalize-file-buffer-names)
    (remove-hook 'post-command-hook
!              'delayed-uniquify-rationalize-file-buffer-names))
  
! (add-hook 'kill-buffer-hook 'delay-uniquify-rationalize-file-buffer-names)
  
  ;;; uniquify.el ends here
--- 385,407 ----
  ;; (This ought to set some global variables so the work is done only for
  ;; buffers with names similar to the deleted buffer.  -MDE)
  
! (defun uniquify-delay-rationalize-file-buffer-names ()
    "Add `delayed-uniquify-rationalize-file-buffer-names' to 
`post-command-hook'.
  For use on, eg, `kill-buffer-hook', to rationalize *after* buffer deletion."
    (if (and uniquify-buffer-name-style
!          uniquify-after-kill-buffer-p
!          ;; Rationalizing is costly, so don't do it for temp buffers.
!          (uniquify-buffer-file-name (current-buffer)))
        (add-hook 'post-command-hook
!               'uniquify-delayed-rationalize-file-buffer-names)))
  
! (defun uniquify-delayed-rationalize-file-buffer-names ()
    "Rerationalize buffer names and remove self from `post-command-hook'.
  See also `delay-rationalize-file-buffer-names' for hook setter."
    (uniquify-rationalize-file-buffer-names)
    (remove-hook 'post-command-hook
!              'uniquify-delayed-rationalize-file-buffer-names))
  
! (add-hook 'kill-buffer-hook 'uniquify-delay-rationalize-file-buffer-names)
  
  ;;; uniquify.el ends here



reply via email to

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