* riece-button.el (riece-button-disable): On XEmacs, BUFFER arg of
authorueno <ueno>
Tue, 1 Jun 2004 09:30:31 +0000 (09:30 +0000)
committerueno <ueno>
Tue, 1 Jun 2004 09:30:31 +0000 (09:30 +0000)
widget-map-buttons is ignored.

lisp/ChangeLog
lisp/riece-button.el

index b937469..b454ec3 100644 (file)
@@ -1,5 +1,10 @@
 2004-06-01  Daiki Ueno  <ueno@unixuser.org>
 
+       * riece-button.el (riece-button-disable): On XEmacs, BUFFER arg of
+       widget-map-buttons is ignored.
+
+2004-06-01  Daiki Ueno  <ueno@unixuser.org>
+
        * riece-unread.el (riece-modeline-unread-face): New face;
        setup the properties are inherited from 'modeline.
        * riece-history.el (riece-modeline-history-face): New face;
index f92eeb7..a3b915c 100644 (file)
@@ -241,13 +241,15 @@ This function is used as a callback for a channel button."
 
 (defun riece-button-disable ()
   (setq riece-button-enabled nil)
-  (let ((pointer riece-buffer-list))
-    (while pointer
-      (widget-map-buttons
-       (lambda (widget maparg)
-        (widget-leave-text widget))
-       (car pointer))
-      (setq pointer (cdr pointer)))))
+  (save-excursion
+    (let ((pointer riece-buffer-list))
+      (while pointer
+       ;; On XEmacs, BUFFER arg of widget-map-buttons is ignored.
+       (set-buffer (car pointer))
+       (widget-map-buttons
+        (lambda (widget maparg)
+          (widget-leave-text widget)))
+       (setq pointer (cdr pointer))))))
 
 (provide 'riece-button)