* riece-commands.el (riece-command-names): New command.
authorueno <ueno>
Thu, 29 May 2003 09:45:22 +0000 (09:45 +0000)
committerueno <ueno>
Thu, 29 May 2003 09:45:22 +0000 (09:45 +0000)
(riece-command-who): New command.

* riece.el (riece-dialogue-mode-map): Bind riece-command-names and
riece-command-who.

lisp/ChangeLog
lisp/riece-commands.el
lisp/riece.el

index 5b750a9..0c01923 100644 (file)
@@ -1,5 +1,11 @@
 2003-05-29  Daiki Ueno  <ueno@unixuser.org>
 
+       * riece-commands.el (riece-command-names): New command.
+       (riece-command-who): New command.
+
+       * riece.el (riece-dialogue-mode-map): Bind riece-command-names and
+       riece-command-who.
+
        * riece-300.el (riece-handle-341-message): New handler.
        (riece-handle-352-message): New handler.
 
index 6b84c48..f00eb99 100644 (file)
             (riece-identity-prefix riece-current-channel)
             user))))
 
+(defun riece-command-names (pattern)
+  (interactive
+   (let ((completion-ignore-case t))
+     (list (read-from-minibuffer
+           "Pattern: "
+           (if (and riece-current-channel
+                    (riece-channel-p riece-current-channel))
+               (cons (riece-identity-prefix riece-current-channel)
+                     0))))))
+  (if (or (not (equal pattern ""))
+         (yes-or-no-p "Really want to query NAMES without argument? "))
+      (riece-send-string (format "NAMES %s\r\n" pattern))))
+
+(defun riece-command-who (pattern)
+  (interactive
+   (let ((completion-ignore-case t))
+     (list (read-from-minibuffer
+           "Pattern: "
+           (if (and riece-current-channel
+                    (riece-channel-p riece-current-channel))
+               (cons (riece-identity-prefix riece-current-channel)
+                     0))))))
+  (if (or (not (equal pattern ""))
+         (yes-or-no-p "Really want to query WHO without argument? "))
+      (riece-send-string (format "WHO %s\r\n" pattern))))
+
 (defun riece-command-change-mode (channel change)
   (interactive
    (let* ((completion-ignore-case t)
index dd7e2c9..75f38e7 100644 (file)
@@ -151,6 +151,7 @@ If optional argument SAFE is nil, overwrite previous definitions."
     "m" riece-dialogue-enter-message
     "M" riece-command-change-mode
     "n" riece-command-change-nickname
+    "\C-n" riece-command-names
     "o" other-window
     "O" riece-command-open-server
     "C" riece-command-close-server
@@ -158,7 +159,8 @@ If optional argument SAFE is nil, overwrite previous definitions."
     "q" riece-command-quit
     "r" riece-command-configure-windows
     "x" riece-command-copy-region
-    "t" riece-command-topic)
+    "t" riece-command-topic
+    "w" riece-command-who)
 
   (riece-define-keys riece-command-mode-map
     "\r" riece-command-enter-message