diff options
Diffstat (limited to 'protocols/nogaim.c')
| -rw-r--r-- | protocols/nogaim.c | 16 | 
1 files changed, 13 insertions, 3 deletions
| diff --git a/protocols/nogaim.c b/protocols/nogaim.c index b65ddaf5..4966a76f 100644 --- a/protocols/nogaim.c +++ b/protocols/nogaim.c @@ -767,15 +767,25 @@ void serv_got_im( struct gaim_connection *gc, char *handle, char *msg, guint32 f  	irc_msgfrom( irc, u->nick, msg );  } -void serv_got_typing( struct gaim_connection *gc, char *handle, int timeout ) +void serv_got_typing( struct gaim_connection *gc, char *handle, int timeout, int type )  {  	user_t *u;  	if( !set_getint( gc->irc, "typing_notice" ) )  		return; -	if( ( u = user_findhandle( gc, handle ) ) ) -		irc_privmsg( gc->irc, u, "PRIVMSG", gc->irc->nick, NULL, "\1TYPING 1\1" ); +	if( ( u = user_findhandle( gc, handle ) ) ) { +		/* If type is: +		 * 0: user has stopped typing +		 * 1: user is actively typing +		 * 2: user has entered text, but is not actively typing +		 */ +		if (type == 0 || type == 1 || type == 2) { +			char buf[256];  +			g_snprintf(buf, 256, "\1TYPING %d\1", type);  +			irc_privmsg( gc->irc, u, "PRIVMSG", gc->irc->nick, NULL, buf ); +		} +	}  }  void serv_got_chat_left( struct gaim_connection *gc, int id ) | 
