emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] master fd86149: Avoid potential extensive verbosity in gnu


From: Sam Steingold
Subject: [Emacs-diffs] master fd86149: Avoid potential extensive verbosity in gnus-summary-browse-url
Date: Wed, 24 Jul 2019 12:15:24 -0400 (EDT)

branch: master
commit fd86149b1a05a38a9d21616003107aa2ab2e6c3f
Author: Sam Steingold <address@hidden>
Commit: Sam Steingold <address@hidden>

    Avoid potential extensive verbosity in gnus-summary-browse-url
    
    * lisp/wid-edit.el (widget-move): Accept suppress-echo argument.
    * lisp/gnus/gnus-sum.el (gnus-collect-urls): Use it.
---
 lisp/gnus/gnus-sum.el | 2 +-
 lisp/wid-edit.el      | 9 ++++++---
 2 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/lisp/gnus/gnus-sum.el b/lisp/gnus/gnus-sum.el
index 1f330e3..fdecad4 100644
--- a/lisp/gnus/gnus-sum.el
+++ b/lisp/gnus/gnus-sum.el
@@ -9438,7 +9438,7 @@ With optional ARG, move across that many fields."
   "Return the list of URLs in the buffer after (point).
 The 1st element is the one named 'Link', if any."
   (let ((pt (point)) urls link)
-    (while (progn (widget-move 1)
+    (while (progn (widget-move 1 t) ; no echo
                  ;; `widget-move' wraps around to top of buffer.
                  (> (point) pt))
       (setq pt (point))
diff --git a/lisp/wid-edit.el b/lisp/wid-edit.el
index b96f6aa..dd03a24 100644
--- a/lisp/wid-edit.el
+++ b/lisp/wid-edit.el
@@ -1040,9 +1040,11 @@ POS defaults to the value of (point)."
   "If non-nil, use overlay change functions to tab around in the buffer.
 This is much faster.")
 
-(defun widget-move (arg)
+(defun widget-move (arg &optional suppress-echo)
   "Move point to the ARG next field or button.
-ARG may be negative to move backward."
+ARG may be negative to move backward.
+When the second optional argument is non-nil,
+nothing is shown in the echo area."
   (or (bobp) (> arg 0) (backward-char))
   (let ((wrapped 0)
        (number arg)
@@ -1084,7 +1086,8 @@ ARG may be negative to move backward."
       (while (eq (widget-tabable-at) new)
        (backward-char)))
     (forward-char))
-  (widget-echo-help (point))
+  (unless suppress-echo
+    (widget-echo-help (point)))
   (run-hooks 'widget-move-hook))
 
 (defun widget-forward (arg)



reply via email to

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