comparison libpurple/protocols/gg/gg.c @ 21418:38cc722159ff

propagate from branch 'im.pidgin.pidgin' (head d8103be97302efb404e2f6922925f661c807ad23) to branch 'im.pidgin.cpw.resiak.disconnectreason' (head 0ac25a1f38ae28654c967caa143f1c0d12ef2e1c)
author Will Thompson <will.thompson@collabora.co.uk>
date Sat, 10 Nov 2007 12:10:04 +0000
parents e747ac0c42d6 6de09629f091
children 1ce05db42eb3
comparison
equal deleted inserted replaced
21417:21bea7c72a80 21418:38cc722159ff
831 /* static void ggp_callback_add_to_chat_ok(PurpleConnection *gc, PurpleRequestFields *fields) {{{ */ 831 /* static void ggp_callback_add_to_chat_ok(PurpleConnection *gc, PurpleRequestFields *fields) {{{ */
832 static void ggp_callback_add_to_chat_ok(PurpleConnection *gc, PurpleRequestFields *fields) 832 static void ggp_callback_add_to_chat_ok(PurpleConnection *gc, PurpleRequestFields *fields)
833 { 833 {
834 GGPInfo *info = gc->proto_data; 834 GGPInfo *info = gc->proto_data;
835 PurpleRequestField *field; 835 PurpleRequestField *field;
836 /* TODO: sel may be null. */
836 GList *sel; 837 GList *sel;
837 838
838 field = purple_request_fields_get_field(fields, "name"); 839 field = purple_request_fields_get_field(fields, "name");
839 sel = purple_request_field_list_get_selected(field); 840 sel = purple_request_field_list_get_selected(field);
840 841
1879 g_free(tmp); 1880 g_free(tmp);
1880 1881
1881 gg_change_status_descr(info->session, new_status_descr, new_msg); 1882 gg_change_status_descr(info->session, new_status_descr, new_msg);
1882 g_free(new_msg); 1883 g_free(new_msg);
1883 } 1884 }
1885
1886 ggp_status_fake_to_self(account);
1887
1884 } 1888 }
1885 /* }}} */ 1889 /* }}} */
1886 1890
1887 /* static void ggp_add_buddy(PurpleConnection *gc, PurpleBuddy *buddy, PurpleGroup *group) {{{ */ 1891 /* static void ggp_add_buddy(PurpleConnection *gc, PurpleBuddy *buddy, PurpleGroup *group) {{{ */
1888 static void ggp_add_buddy(PurpleConnection *gc, PurpleBuddy *buddy, PurpleGroup *group) 1892 static void ggp_add_buddy(PurpleConnection *gc, PurpleBuddy *buddy, PurpleGroup *group)
1889 { 1893 {
1894 PurpleAccount *account;
1890 GGPInfo *info = gc->proto_data; 1895 GGPInfo *info = gc->proto_data;
1891 1896
1892 gg_add_notify(info->session, ggp_str_to_uin(buddy->name)); 1897 gg_add_notify(info->session, ggp_str_to_uin(buddy->name));
1898
1899 account = purple_connection_get_account(gc);
1900 if (strcmp(purple_account_get_username(account), buddy->name) == 0) {
1901 ggp_status_fake_to_self(account);
1902 }
1893 } 1903 }
1894 /* }}} */ 1904 /* }}} */
1895 1905
1896 /* static void ggp_remove_buddy(PurpleConnection *gc, PurpleBuddy *buddy, PurpleGroup *group) {{{ */ 1906 /* static void ggp_remove_buddy(PurpleConnection *gc, PurpleBuddy *buddy, PurpleGroup *group) {{{ */
1897 static void ggp_remove_buddy(PurpleConnection *gc, PurpleBuddy *buddy, 1907 static void ggp_remove_buddy(PurpleConnection *gc, PurpleBuddy *buddy,
2161 NULL, /* dependencies */ 2171 NULL, /* dependencies */
2162 PURPLE_PRIORITY_DEFAULT, /* priority */ 2172 PURPLE_PRIORITY_DEFAULT, /* priority */
2163 2173
2164 "prpl-gg", /* id */ 2174 "prpl-gg", /* id */
2165 "Gadu-Gadu", /* name */ 2175 "Gadu-Gadu", /* name */
2166 VERSION, /* version */ 2176 DISPLAY_VERSION, /* version */
2167 2177
2168 N_("Gadu-Gadu Protocol Plugin"), /* summary */ 2178 N_("Gadu-Gadu Protocol Plugin"), /* summary */
2169 N_("Polish popular IM"), /* description */ 2179 N_("Polish popular IM"), /* description */
2170 "boler@sourceforge.net", /* author */ 2180 "boler@sourceforge.net", /* author */
2171 PURPLE_WEBSITE, /* homepage */ 2181 PURPLE_WEBSITE, /* homepage */