changeset 23533:10a3478e3432

(Info-next-menu-item): Stay on top of node.
author Richard M. Stallman <rms@gnu.org>
date Thu, 22 Oct 1998 01:35:03 +0000
parents a493aa84f62f
children 6f9c70db3a58
files lisp/info.el
diffstat 1 files changed, 8 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/info.el	Wed Oct 21 20:24:41 1998 +0000
+++ b/lisp/info.el	Thu Oct 22 01:35:03 1998 +0000
@@ -1357,12 +1357,14 @@
 
 (defun Info-next-menu-item ()
   (interactive)
-  (save-excursion
-    (forward-line -1)
-    (search-forward "\n* menu:" nil t)
-    (or (search-forward "\n* " nil t)
-	(error "No more items in menu"))
-    (Info-goto-node (Info-extract-menu-node-name))))
+  (let ((node
+	 (save-excursion
+	   (forward-line -1)
+	   (search-forward "\n* menu:" nil t)
+	   (and (search-forward "\n* " nil t)
+		(Info-extract-menu-node-name)))))
+    (if node (Info-goto-node node)
+      (error "No more items in menu"))))
 
 (defun Info-last-menu-item ()
   (interactive)