# HG changeset patch # User Carsten Dominik # Date 1124878709 0 # Node ID 83940123c4b3529e4e6e46a575d0341d709a41a8 # Parent aaf3a41389582b3b7117f2402fa70bb74c38dd68 (bookmark-after-jump-hook): New hook. (bookmark-jump): Run `bookmark-after-jump-hook'. diff -r aaf3a4138958 -r 83940123c4b3 lisp/bookmark.el --- a/lisp/bookmark.el Wed Aug 24 10:17:14 2005 +0000 +++ b/lisp/bookmark.el Wed Aug 24 10:18:29 2005 +0000 @@ -1037,6 +1037,10 @@ (lambda (x y) (string-lessp (car x) (car y)))))))) +(defvar bookmark-after-jump-hook nil + "Hook run after `bookmark-jump' jumps to a bookmark. +Useful for example to unhide text in `outline-mode'.") + ;;;###autoload (defun bookmark-jump (bookmark) "Jump to bookmark BOOKMARK (a point in some file). @@ -1059,6 +1063,7 @@ (and cell (switch-to-buffer (car cell)) (goto-char (cdr cell)) + (progn (run-hooks 'bookmark-jump-hook) t) (if bookmark-automatically-show-annotations ;; if there is an annotation for this bookmark, ;; show it in a buffer.