emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] emacs/lisp bookmark.el ChangeLog


From: Karl Fogel
Subject: [Emacs-diffs] emacs/lisp bookmark.el ChangeLog
Date: Fri, 09 Oct 2009 05:55:02 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Changes by:     Karl Fogel <kfogel>     09/10/09 05:55:01

Modified files:
        lisp           : bookmark.el ChangeLog 

Log message:
        * lisp/bookmark.el (bookmark-jump): Add new `display-func' parameter.
          (bookmark-jump-other-window): Just invoke bookmark-jump with new
          argument now, so the two function's behaviors will match.  (Bug#3645)

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/emacs/lisp/bookmark.el?cvsroot=emacs&r1=1.131&r2=1.132
http://cvs.savannah.gnu.org/viewcvs/emacs/lisp/ChangeLog?cvsroot=emacs&r1=1.16391&r2=1.16392

Patches:
Index: bookmark.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/bookmark.el,v
retrieving revision 1.131
retrieving revision 1.132
diff -u -b -r1.131 -r1.132
--- bookmark.el 5 Oct 2009 04:19:04 -0000       1.131
+++ bookmark.el 9 Oct 2009 05:54:57 -0000       1.132
@@ -989,7 +989,7 @@
 
 
 ;;;###autoload
-(defun bookmark-jump (bookmark)
+(defun bookmark-jump (bookmark &optional display-func)
   "Jump to bookmark BOOKMARK (a point in some file).
 You may have a problem using this function if the value of variable
 `bookmark-alist' is nil.  If that happens, you need to load in some
@@ -1002,27 +1002,27 @@
 of the old one in the permanent bookmark record.
 
 BOOKMARK may be a bookmark name (a string) or a bookmark record, but
-the latter is usually only used by programmatic callers."
+the latter is usually only used by programmatic callers.
+
+If DISPLAY-FUNC is non-nil, it is a function to invoke to display the
+bookmark.  It defaults to `switch-to-buffer'; a typical other value
+would be, e.g., `switch-to-buffer-other-window'."
   (interactive
    (list (bookmark-completing-read "Jump to bookmark"
                                   bookmark-current-bookmark)))
   (unless bookmark
     (error "No bookmark specified"))
   (bookmark-maybe-historicize-string bookmark)
-  (bookmark--jump-via bookmark 'switch-to-buffer))
+  (bookmark--jump-via bookmark (or display-func 'switch-to-buffer)))
 
 
 ;;;###autoload
 (defun bookmark-jump-other-window (bookmark)
   "Jump to BOOKMARK in another window.  See `bookmark-jump' for more."
   (interactive
-   (let ((bkm (bookmark-completing-read "Jump to bookmark (in another window)"
+   (list (bookmark-completing-read "Jump to bookmark (in another window)"
                                         bookmark-current-bookmark)))
-     (if (> emacs-major-version 21)
-         (list bkm) bkm)))
-  (when bookmark
-    (bookmark-maybe-historicize-string bookmark)
-    (bookmark--jump-via bookmark 'switch-to-buffer-other-window)))
+  (bookmark-jump bookmark 'switch-to-buffer-other-window))
 
 
 (defun bookmark-jump-noselect (bookmark)

Index: ChangeLog
===================================================================
RCS file: /sources/emacs/emacs/lisp/ChangeLog,v
retrieving revision 1.16391
retrieving revision 1.16392
diff -u -b -r1.16391 -r1.16392
--- ChangeLog   8 Oct 2009 22:13:42 -0000       1.16391
+++ ChangeLog   9 Oct 2009 05:54:58 -0000       1.16392
@@ -1,3 +1,9 @@
+2009-10-09  Karl Fogel  <address@hidden>
+
+       * bookmark.el (bookmark-jump): Add new `display-func' parameter.
+       (bookmark-jump-other-window): Just invoke bookmark-jump with new
+       argument now, so the two function's behaviors will match.  (Bug#3645)
+
 2009-10-08  Chong Yidong  <address@hidden>
 
        * cedet/ede/proj.el (project-make-dist, project-compile-project):




reply via email to

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