* wl-summary.el (wl-summary-mode-map): Bind wl-summary-next-buffer
authorteranisi <teranisi>
Tue, 5 Mar 2002 09:37:33 +0000 (09:37 +0000)
committerteranisi <teranisi>
Tue, 5 Mar 2002 09:37:33 +0000 (09:37 +0000)
and wl-summary-previous-buffer.
(wl-summary-next-buffer): New function.
(wl-summary-previous-buffer): Ditto.

wl/ChangeLog
wl/wl-summary.el

index 8f76bd6..c310ed2 100644 (file)
@@ -1,3 +1,10 @@
+2002-03-05  Yuuichi Teranishi  <teranisi@gohome.org>
+
+       * wl-summary.el (wl-summary-mode-map): Bind wl-summary-next-buffer
+       and wl-summary-previous-buffer.
+       (wl-summary-next-buffer): New function.
+       (wl-summary-previous-buffer): Ditto.
+
 2002-03-05  Yoichi NAKAYAMA  <yoichi@eken.phys.nagoya-u.ac.jp>
 
        * wl-folder.el (toplevel): Bind [(shift return)] to
index 79fa995..1caa60d 100644 (file)
   (define-key wl-summary-mode-map "e"     'wl-summary-save)
   (define-key wl-summary-mode-map "\C-c\C-o" 'wl-jump-to-draft-buffer)
   (define-key wl-summary-mode-map "\C-c\C-a" 'wl-addrmgr)
+  (define-key wl-summary-mode-map "\C-c\C-p" 'wl-summary-next-buffer)
+  (define-key wl-summary-mode-map "\C-c\C-n" 'wl-summary-previous-buffer)
   (define-key wl-summary-mode-map "H"    'wl-summary-redisplay-all-header)
   (define-key wl-summary-mode-map "M"    'wl-summary-redisplay-no-mime)
   (define-key wl-summary-mode-map "B"    'wl-summary-burst)
@@ -3920,6 +3922,28 @@ If ARG, exit virtual folder."
                (delq (car mlist) wl-summary-buffer-target-mark-list))
          (setq mlist (cdr mlist)))))))
 
+(defun wl-summary-next-buffer ()
+  "Switch to next summary buffer."
+  (interactive)
+  (let ((buffers (sort (wl-collect-summary)
+                      (lambda (buffer1 buffer2)
+                        (string-lessp (buffer-name buffer1)
+                                      (buffer-name buffer2))))))
+    (switch-to-buffer
+     (or (cadr (memq (current-buffer) buffers))
+        (car buffers)))))
+
+(defun wl-summary-previous-buffer ()
+  "Switch to previous summary buffer."
+  (interactive)
+  (let ((buffers (sort (wl-collect-summary)
+                      (lambda (buffer1 buffer2)
+                        (not (string-lessp (buffer-name buffer1)
+                                           (buffer-name buffer2)))))))
+    (switch-to-buffer
+     (or (cadr (memq (current-buffer) buffers))
+        (car buffers)))))
+
 (defun wl-summary-target-mark-copy ()
   (interactive)
   (wl-summary-target-mark-refile-subr "copy"))