Mercurial > pidgin.yaz
comparison src/protocols/yahoo/yahoo.c @ 13842:a9ff4499d9ce
[gaim-migrate @ 16295]
Hopefully improve the typing notification code so it's a lot easier
to understand. This also creates a distinction between the signals
emitted when receiving GAIM_TYPED and GAIM_NOT_TYPING messages
(by adding a gaim-typed signal). And the gaim-not-typing signal
should work in all cases.
Most of this is stuff I changed last week during work, thanks to
Meebo
committer: Tailor Script <tailor@pidgin.im>
author | Mark Doliner <mark@kingant.net> |
---|---|
date | Tue, 20 Jun 2006 08:17:49 +0000 |
parents | 967ef719cb62 |
children | 8d1c55309e3c |
comparison
equal
deleted
inserted
replaced
13841:f3d4a9902ead | 13842:a9ff4499d9ce |
---|---|
3129 g_free(msg2); | 3129 g_free(msg2); |
3130 | 3130 |
3131 return ret; | 3131 return ret; |
3132 } | 3132 } |
3133 | 3133 |
3134 static int yahoo_send_typing(GaimConnection *gc, const char *who, int typ) | 3134 static unsigned int yahoo_send_typing(GaimConnection *gc, const char *who, GaimTypingState state) |
3135 { | 3135 { |
3136 struct yahoo_data *yd = gc->proto_data; | 3136 struct yahoo_data *yd = gc->proto_data; |
3137 struct yahoo_packet *pkt = yahoo_packet_new(YAHOO_SERVICE_NOTIFY, YAHOO_STATUS_TYPING, 0); | 3137 struct yahoo_packet *pkt = yahoo_packet_new(YAHOO_SERVICE_NOTIFY, YAHOO_STATUS_TYPING, 0); |
3138 yahoo_packet_hash(pkt, "ssssss", 49, "TYPING", 1, gaim_connection_get_display_name(gc), | 3138 yahoo_packet_hash(pkt, "ssssss", 49, "TYPING", 1, gaim_connection_get_display_name(gc), |
3139 14, " ", 13, typ == GAIM_TYPING ? "1" : "0", | 3139 14, " ", 13, state == GAIM_TYPING ? "1" : "0", |
3140 5, who, 1002, "1"); | 3140 5, who, 1002, "1"); |
3141 | 3141 |
3142 yahoo_packet_send_and_free(pkt, yd); | 3142 yahoo_packet_send_and_free(pkt, yd); |
3143 | 3143 |
3144 return 0; | 3144 return 0; |