[beirc-cvs] CVS update: beirc/beirc.lisp beirc/message-display.lisp

Andreas Fuchs afuchs at common-lisp.net
Sat Sep 17 22:34:04 UTC 2005


Update of /project/beirc/cvsroot/beirc
In directory common-lisp.net:/tmp/cvs-serv4524

Modified Files:
	beirc.lisp message-display.lisp 
Log Message:
fix highlighting of yor own nickname (which broke in the last checkin).

Date: Sun Sep 18 00:34:02 2005
Author: afuchs

Index: beirc/beirc.lisp
diff -u beirc/beirc.lisp:1.11 beirc/beirc.lisp:1.12
--- beirc/beirc.lisp:1.11	Sun Sep 18 00:22:57 2005
+++ beirc/beirc.lisp	Sun Sep 18 00:34:00 2005
@@ -400,7 +400,10 @@
 
 (defun nick-equals-my-nick-p (nickname)
   (and *application-frame*
-       (string= nickname (slot-value *application-frame* 'nick))))
+       (equal (irc:normalize-nickname (current-connection *application-frame*)
+                                      (slot-value *application-frame* 'nick))
+              (irc:normalize-nickname (current-connection *application-frame*)
+                                      nickname))))
 
 (define-presentation-method present (o (type nickname) *standard-output* (view textual-view) &key)
   (if (nick-equals-my-nick-p o)


Index: beirc/message-display.lisp
diff -u beirc/message-display.lisp:1.2 beirc/message-display.lisp:1.3
--- beirc/message-display.lisp:1.2	Sun Sep 18 00:22:57 2005
+++ beirc/message-display.lisp	Sun Sep 18 00:34:00 2005
@@ -75,7 +75,9 @@
                (cond
                  ((search "http://" word*)
                   (present-url word*))
-                 ((irc:find-user (current-connection *application-frame*) word*)
+                 ((or
+                   (nick-equals-my-nick-p word*)
+                   (irc:find-user (current-connection *application-frame*) word*))
                   (present word* 'nickname))
                  (t (write-string word*)))
                (write-string stripped-punctuation))




More information about the Beirc-cvs mailing list