Mercurial > pidgin.yaz
comparison src/gtkblist.c @ 9918:c203312d8224
[gaim-migrate @ 10810]
(21:52:28) noif: LSchiere: now that datallah's patch is applied, I've got
another that uses the prpl method he added. This makes the add/remove
button on chats update properly when a chat is added or removed from the
list:
committer: Tailor Script <tailor@pidgin.im>
author | Luke Schierer <lschiere@pidgin.im> |
---|---|
date | Tue, 31 Aug 2004 01:58:52 +0000 |
parents | e74eb0d11f86 |
children | 4e7590473515 |
comparison
equal
deleted
inserted
replaced
9917:e74eb0d11f86 | 9918:c203312d8224 |
---|---|
4110 GHashTable *components; | 4110 GHashTable *components; |
4111 GList *tmp; | 4111 GList *tmp; |
4112 GaimChat *chat; | 4112 GaimChat *chat; |
4113 GaimGroup *group; | 4113 GaimGroup *group; |
4114 const char *group_name; | 4114 const char *group_name; |
4115 char *chat_name = NULL; | |
4116 GaimConversation *conv = NULL; | |
4115 | 4117 |
4116 components = g_hash_table_new_full(g_str_hash, g_str_equal, | 4118 components = g_hash_table_new_full(g_str_hash, g_str_equal, |
4117 g_free, g_free); | 4119 g_free, g_free); |
4118 | 4120 |
4119 for (tmp = data->entries; tmp; tmp = tmp->next) | 4121 for (tmp = data->entries; tmp; tmp = tmp->next) |
4146 } | 4148 } |
4147 | 4149 |
4148 if (chat != NULL) | 4150 if (chat != NULL) |
4149 { | 4151 { |
4150 gaim_blist_add_chat(chat, group, NULL); | 4152 gaim_blist_add_chat(chat, group, NULL); |
4153 | |
4154 if (GAIM_PLUGIN_PROTOCOL_INFO(data->account->gc->prpl)->get_chat_name != NULL) | |
4155 chat_name = GAIM_PLUGIN_PROTOCOL_INFO( | |
4156 data->account->gc->prpl)->get_chat_name(chat->components); | |
4157 | |
4158 if (chat_name != NULL) { | |
4159 conv = gaim_find_conversation_with_account(chat_name, data->account); | |
4160 g_free(chat_name); | |
4161 } | |
4162 | |
4163 if (conv != NULL) | |
4164 gaim_conversation_update(conv, GAIM_CONV_UPDATE_ADD); | |
4151 } | 4165 } |
4152 | 4166 |
4153 gtk_widget_destroy(data->window); | 4167 gtk_widget_destroy(data->window); |
4154 g_free(data->default_chat_name); | 4168 g_free(data->default_chat_name); |
4155 g_list_free(data->entries); | 4169 g_list_free(data->entries); |