emacs-diffs
[Top][All Lists]
Advanced

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

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


From: Chong Yidong
Subject: [Emacs-diffs] emacs/lisp ChangeLog tooltip.el
Date: Mon, 06 Apr 2009 23:52:45 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Changes by:     Chong Yidong <cyd>      09/04/06 23:52:45

Modified files:
        lisp           : ChangeLog tooltip.el 

Log message:
        * tooltip.el (tooltip-show-help-non-mode): Don't save the last
        message if it was also a help message (Bug#2895).

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/emacs/lisp/ChangeLog?cvsroot=emacs&r1=1.15552&r2=1.15553
http://cvs.savannah.gnu.org/viewcvs/emacs/lisp/tooltip.el?cvsroot=emacs&r1=1.92&r2=1.93

Patches:
Index: ChangeLog
===================================================================
RCS file: /sources/emacs/emacs/lisp/ChangeLog,v
retrieving revision 1.15552
retrieving revision 1.15553
diff -u -b -r1.15552 -r1.15553
--- ChangeLog   6 Apr 2009 20:44:15 -0000       1.15552
+++ ChangeLog   6 Apr 2009 23:52:41 -0000       1.15553
@@ -1,3 +1,8 @@
+2009-04-06  Chong Yidong  <address@hidden>
+
+       * tooltip.el (tooltip-show-help-non-mode): Don't save the last
+       message if it was also a help message (Bug#2895).
+
 2009-04-06  Roland Winkler  <address@hidden>
 
        * textmodes/bibtex.el (bibtex-format-entry)

Index: tooltip.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/tooltip.el,v
retrieving revision 1.92
retrieving revision 1.93
diff -u -b -r1.92 -r1.93
--- tooltip.el  16 Mar 2009 02:42:45 -0000      1.92
+++ tooltip.el  6 Apr 2009 23:52:44 -0000       1.93
@@ -319,7 +319,9 @@
 ;;; Tooltip help.
 
 (defvar tooltip-help-message nil
-  "The last help message received via `tooltip-show-help'.")
+  "The last help message received via `show-help-function'.
+This is used by `tooltip-show-help' and
+`tooltip-show-help-non-mode'.")
 
 (defvar tooltip-previous-message nil
   "The previous content of the echo area.")
@@ -327,16 +329,17 @@
 (defun tooltip-show-help-non-mode (help)
   "Function installed as `show-help-function' when tooltip is off."
   (when (and (not (window-minibuffer-p)) ;Don't overwrite minibuffer contents.
-             ;; Don't know how to reproduce it in Elisp:
-             ;; Don't overwrite a keystroke echo.
-             ;; (NILP (echo_message_buffer) || ok_to_overwrite_keystroke_echo)
              (not cursor-in-echo-area)) ;Don't overwrite a prompt.
     (cond
      ((stringp help)
       (setq help (replace-regexp-in-string "\n" ", " help))
       (unless (or tooltip-previous-message
-                 (string-equal help (current-message)))
+                 (string-equal help (current-message))
+                 (and (stringp tooltip-help-message)
+                      (string-equal tooltip-help-message
+                                    (current-message))))
         (setq tooltip-previous-message (current-message)))
+      (setq tooltip-help-message help)
       (let ((message-truncate-lines t)
             (message-log-max nil))
         (message "%s" help)))




reply via email to

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