267
268
269
270
271
272
273
274
275
276
277
278
279
280
|
@selector(connection:didSeeUserQuit:withReason:)])
[delegate connection: self
didSeeUserQuit: user
withReason: reason];
continue;
}
/* PRIVMSG */
if ([action isEqual: @"PRIVMSG"] && split.count >= 4) {
OFString *from = [split objectAtIndex: 0];
OFString *to = [split objectAtIndex: 2];
IRCUser *user;
OFString *msg;
|
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
|
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
|
@selector(connection:didSeeUserQuit:withReason:)])
[delegate connection: self
didSeeUserQuit: user
withReason: reason];
continue;
}
/* NICK */
if ([action isEqual: @"NICK"] && split.count == 3) {
OFString *who = [split objectAtIndex: 0];
OFString *newNickname = [split objectAtIndex: 2];
IRCUser *user;
who = [who substringWithRange:
of_range(1, who.length - 1)];
newNickname = [newNickname substringWithRange:
of_range(1, newNickname.length - 1)];
user = [IRCUser IRCUserWithString: who];
if ([delegate respondsToSelector:
@selector(connection:didSeeUser:changeNicknameTo:)])
[delegate connection: self
didSeeUser: user
changeNicknameTo: newNickname];
}
/* PRIVMSG */
if ([action isEqual: @"PRIVMSG"] && split.count >= 4) {
OFString *from = [split objectAtIndex: 0];
OFString *to = [split objectAtIndex: 2];
IRCUser *user;
OFString *msg;
|