comparison src/protocols/toc/toc.c @ 9754:4a8bf81b82ae

[gaim-migrate @ 10621] " This will default the room/server fields to the proper values when an add chat is requested from a conversation window. It wasn't quite as trivial as the reporter suggested..." --Nathan (noif) Fredrickson committer: Tailor Script <tailor@pidgin.im>
author Luke Schierer <lschiere@pidgin.im>
date Sun, 15 Aug 2004 19:34:20 +0000
parents db62420a53a2
children c28d5b45624e
comparison
equal deleted inserted replaced
9753:60705fd4f411 9754:4a8bf81b82ae
1276 m = g_list_append(m, pce); 1276 m = g_list_append(m, pce);
1277 1277
1278 return m; 1278 return m;
1279 } 1279 }
1280 1280
1281 GHashTable *toc_chat_info_defaults(GaimConnection *gc, const char *chat_name)
1282 {
1283 GHashTable *defaults;
1284
1285 defaults = g_hash_table_new_full(g_str_hash, g_str_equal, NULL, g_free);
1286
1287 if (chat_name != NULL)
1288 g_hash_table_insert(defaults, "room", g_strdup(chat_name));
1289
1290 return defaults;
1291 }
1292
1281 static void toc_join_chat(GaimConnection *g, GHashTable *data) 1293 static void toc_join_chat(GaimConnection *g, GHashTable *data)
1282 { 1294 {
1283 char buf[BUF_LONG]; 1295 char buf[BUF_LONG];
1284 char *name, *exchange; 1296 char *name, *exchange;
1285 char *id; 1297 char *id;
2104 NULL, /* status_text */ 2116 NULL, /* status_text */
2105 NULL, /* tooltip_text */ 2117 NULL, /* tooltip_text */
2106 toc_away_states, /* away_states */ 2118 toc_away_states, /* away_states */
2107 toc_blist_node_menu, /* blist_node_menu */ 2119 toc_blist_node_menu, /* blist_node_menu */
2108 toc_chat_info, /* chat_info */ 2120 toc_chat_info, /* chat_info */
2121 toc_chat_info_defaults, /* chat_info_defaults */
2109 toc_login, /* login */ 2122 toc_login, /* login */
2110 toc_close, /* close */ 2123 toc_close, /* close */
2111 toc_send_im, /* send_im */ 2124 toc_send_im, /* send_im */
2112 toc_set_info, /* set_info */ 2125 toc_set_info, /* set_info */
2113 NULL, /* send_typing */ 2126 NULL, /* send_typing */