* riece-identity.el (riece-completing-read-identity): Pass 6th &
authorueno <ueno>
Sat, 4 Oct 2003 09:42:55 +0000 (09:42 +0000)
committerueno <ueno>
Sat, 4 Oct 2003 09:42:55 +0000 (09:42 +0000)
7th arguments to completing-read.

* riece-commands.el (riece-command-part): Use 6th argument DEFAULT
of riece-completing-read-identity.

* riece-handle.el (riece-handle-invite-message): Fix parsing of
parameters.

* riece-display.el (riece-update-channel-list-buffer): Don't clear
riece-channel-list-changed.
(riece-update-buffers): Clear it.

lisp/ChangeLog
lisp/riece-commands.el
lisp/riece-display.el
lisp/riece-handle.el
lisp/riece-identity.el

index d494fed..094a7e7 100644 (file)
@@ -1,3 +1,18 @@
+2003-10-04  Daiki Ueno  <ueno@unixuser.org>
+
+       * riece-identity.el (riece-completing-read-identity): Pass 6th &
+       7th arguments to completing-read.
+
+       * riece-commands.el (riece-command-part): Use 6th argument DEFAULT
+       of riece-completing-read-identity.
+
+       * riece-handle.el (riece-handle-invite-message): Fix parsing of
+       parameters.
+
+       * riece-display.el (riece-update-channel-list-buffer): Don't clear
+       riece-channel-list-changed.
+       (riece-update-buffers): Clear it.
+
 2003-10-01  Daiki Ueno  <ueno@unixuser.org>
 
        * riece-rdcc.el (riece-rdcc-save-directory): New user option.
index 401678a..3d0f9a9 100644 (file)
@@ -455,8 +455,10 @@ the layout to the selected layout-name."
    (let* ((completion-ignore-case t)
         (target
          (riece-completing-read-identity
-          "Channel/User: " riece-current-channels nil nil
-          (cons (riece-format-identity riece-current-channel) 0)))
+          (format "Channel/User (default %s): "
+                  (riece-format-identity riece-current-channel))
+          riece-current-channels nil nil nil nil
+          (riece-format-identity riece-current-channel)))
         message)
      (if (and current-prefix-arg
              (riece-channel-p (riece-identity-prefix target)))
index 8ddf882..6dcec6a 100644 (file)
@@ -85,8 +85,7 @@
                  (put-text-property point (point) 'riece-identity
                                     (car channels))))
            (setq index (1+ index)
-                 channels (cdr channels))))
-       (setq riece-channel-list-changed nil))))
+                 channels (cdr channels)))))))
 
 (defun riece-update-channel-indicator ()
   (setq riece-channel-indicator
       (setq riece-channel-buffer (get-buffer (riece-channel-buffer-name
                                              riece-current-channel))))
   (run-hooks 'riece-update-buffer-functions)
+  (setq riece-channel-list-changed nil)
   (force-mode-line-update t))
 
 (defun riece-channel-buffer-name (identity)
index 2ca23eb..56852d0 100644 (file)
 (defun riece-handle-invite-message (prefix string)
   (let* ((user (riece-prefix-nickname prefix))
         (parameters (riece-split-parameters string))
-        (channel (car parameters)))
+        (invited (car parameters))
+        (channel (nth 1 parameters)))
     (riece-insert-info
      (list riece-dialogue-buffer riece-others-buffer)
      (concat
       (riece-concat-server-name
-       (format "%s invites you to %s"
+       (format "%s invites %s to %s"
               (riece-format-identity (riece-make-identity
                                       user riece-server-name))
               (riece-format-identity (riece-make-identity
+                                      invited riece-server-name))
+              (riece-format-identity (riece-make-identity
                                       channel riece-server-name))))
       "\n"))))
 
index 0f12d54..098f50f 100644 (file)
@@ -143,8 +143,8 @@ RFC2812, 2.2 \"Character codes\" says:
                         "")))
 
 (defun riece-completing-read-identity (prompt channels
-                                             &optional predicate must-match
-                                             initial)
+                                             &optional predicate require-match
+                                             initial history default)
   (let* ((string
          (completing-read
           prompt
@@ -152,7 +152,7 @@ RFC2812, 2.2 \"Character codes\" says:
                     (list (riece-format-identity channel)))
                   (delq nil (copy-sequence (or channels
                                                riece-current-channels))))
-          predicate must-match initial))
+          predicate require-match initial history default))
         (identity
          (riece-parse-identity string)))
     (unless (string-match (concat "^\\(" riece-channel-regexp "\\|"