Wed, 02 Jun 2010 02:36:24 +0000
Minor comment fix.
Refs: #12078
| 15884 | 1 | /* purple |
| 15030 | 2 | * |
| 15884 | 3 | * Purple is the legal property of its developers, whose names are too numerous |
| 15030 | 4 | * to list here. Please refer to the COPYRIGHT file distributed with this |
| 5 | * source distribution. | |
| 6 | * | |
| 7 | * This program is free software; you can redistribute it and/or modify | |
| 8 | * it under the terms of the GNU General Public License as published by | |
| 9 | * the Free Software Foundation; either version 2 of the License, or | |
| 10 | * (at your option) any later version. | |
| 11 | * | |
| 12 | * This program is distributed in the hope that it will be useful, | |
| 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
| 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
| 15 | * GNU General Public License for more details. | |
| 16 | * | |
| 17 | * You should have received a copy of the GNU General Public License | |
| 18 | * along with this program; if not, write to the Free Software | |
|
19859
71d37b57eff2
The FSF changed its address a while ago; our files were out of date.
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
19050
diff
changeset
|
19 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA |
| 15030 | 20 | * |
| 21 | */ | |
| 22 | ||
| 30403 | 23 | /* libicq is the ICQ protocol plugin. It is linked against liboscar, |
| 15030 | 24 | * which contains all the shared implementation code with libaim |
| 25 | */ | |
| 26 | ||
| 27 | ||
| 28 | #include "oscarcommon.h" | |
| 29 | ||
|
24235
46abfb2f03e4
Show 'ICQ UIN...' and 'Yahoo ID...' in the screenname field
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23277
diff
changeset
|
30 | static GHashTable * |
|
46abfb2f03e4
Show 'ICQ UIN...' and 'Yahoo ID...' in the screenname field
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23277
diff
changeset
|
31 | icq_get_account_text_table(PurpleAccount *account) |
|
46abfb2f03e4
Show 'ICQ UIN...' and 'Yahoo ID...' in the screenname field
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23277
diff
changeset
|
32 | { |
|
46abfb2f03e4
Show 'ICQ UIN...' and 'Yahoo ID...' in the screenname field
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23277
diff
changeset
|
33 | GHashTable *table; |
|
46abfb2f03e4
Show 'ICQ UIN...' and 'Yahoo ID...' in the screenname field
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23277
diff
changeset
|
34 | table = g_hash_table_new(g_str_hash, g_str_equal); |
|
46abfb2f03e4
Show 'ICQ UIN...' and 'Yahoo ID...' in the screenname field
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23277
diff
changeset
|
35 | g_hash_table_insert(table, "login_label", (gpointer)_("ICQ UIN...")); |
|
46abfb2f03e4
Show 'ICQ UIN...' and 'Yahoo ID...' in the screenname field
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23277
diff
changeset
|
36 | return table; |
|
46abfb2f03e4
Show 'ICQ UIN...' and 'Yahoo ID...' in the screenname field
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23277
diff
changeset
|
37 | } |
|
46abfb2f03e4
Show 'ICQ UIN...' and 'Yahoo ID...' in the screenname field
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23277
diff
changeset
|
38 | |
| 15884 | 39 | static PurplePluginProtocolInfo prpl_info = |
| 15030 | 40 | { |
| 41 | OPT_PROTO_MAIL_CHECK | OPT_PROTO_IM_IMAGE, | |
| 42 | NULL, /* user_splits */ | |
| 43 | NULL, /* protocol_options */ | |
|
29859
0166a44a0edd
Current versions of ICQ will happily scale down large icons to 100x100
Mark Doliner <markdoliner@pidgin.im>
parents:
29404
diff
changeset
|
44 | {"gif,jpeg,bmp,ico", 0, 0, 100, 100, 7168, PURPLE_ICON_SCALE_DISPLAY}, /* icon_spec */ |
| 15030 | 45 | oscar_list_icon_icq, /* list_icon */ |
| 15524 | 46 | oscar_list_emblem, /* list_emblems */ |
| 15030 | 47 | oscar_status_text, /* status_text */ |
| 48 | oscar_tooltip_text, /* tooltip_text */ | |
| 49 | oscar_status_types, /* status_types */ | |
| 50 | oscar_blist_node_menu, /* blist_node_menu */ | |
| 51 | oscar_chat_info, /* chat_info */ | |
| 52 | oscar_chat_info_defaults, /* chat_info_defaults */ | |
| 53 | oscar_login, /* login */ | |
| 54 | oscar_close, /* close */ | |
| 55 | oscar_send_im, /* send_im */ | |
| 56 | oscar_set_info, /* set_info */ | |
| 57 | oscar_send_typing, /* send_typing */ | |
| 58 | oscar_get_info, /* get_info */ | |
| 59 | oscar_set_status, /* set_status */ | |
| 60 | oscar_set_idle, /* set_idle */ | |
| 61 | oscar_change_passwd, /* change_passwd */ | |
| 62 | oscar_add_buddy, /* add_buddy */ | |
| 63 | NULL, /* add_buddies */ | |
| 64 | oscar_remove_buddy, /* remove_buddy */ | |
| 65 | NULL, /* remove_buddies */ | |
| 66 | oscar_add_permit, /* add_permit */ | |
| 67 | oscar_add_deny, /* add_deny */ | |
| 68 | oscar_rem_permit, /* rem_permit */ | |
| 69 | oscar_rem_deny, /* rem_deny */ | |
| 70 | oscar_set_permit_deny, /* set_permit_deny */ | |
| 71 | oscar_join_chat, /* join_chat */ | |
| 72 | NULL, /* reject_chat */ | |
| 73 | oscar_get_chat_name, /* get_chat_name */ | |
| 74 | oscar_chat_invite, /* chat_invite */ | |
| 75 | oscar_chat_leave, /* chat_leave */ | |
| 76 | NULL, /* chat_whisper */ | |
| 77 | oscar_send_chat, /* chat_send */ | |
| 78 | oscar_keepalive, /* keepalive */ | |
| 79 | NULL, /* register_user */ | |
| 80 | NULL, /* get_cb_info */ | |
| 81 | NULL, /* get_cb_away */ | |
| 82 | oscar_alias_buddy, /* alias_buddy */ | |
| 83 | oscar_move_buddy, /* group_buddy */ | |
| 84 | oscar_rename_group, /* rename_group */ | |
| 85 | NULL, /* buddy_free */ | |
| 86 | oscar_convo_closed, /* convo_closed */ | |
| 87 | oscar_normalize, /* normalize */ | |
| 88 | oscar_set_icon, /* set_buddy_icon */ | |
|
19050
78ed2f8cd58d
Some changes from Matthew Goldstein and I to not automatically remove
Mark Doliner <markdoliner@pidgin.im>
parents:
18354
diff
changeset
|
89 | oscar_remove_group, /* remove_group */ |
| 15030 | 90 | NULL, /* get_cb_real_name */ |
| 91 | NULL, /* set_chat_topic */ | |
| 92 | NULL, /* find_blist_chat */ | |
| 93 | NULL, /* roomlist_get_list */ | |
| 94 | NULL, /* roomlist_cancel */ | |
| 95 | NULL, /* roomlist_expand_category */ | |
| 96 | oscar_can_receive_file, /* can_receive_file */ | |
| 97 | oscar_send_file, /* send_file */ | |
| 98 | oscar_new_xfer, /* new_xfer */ | |
| 99 | oscar_offline_message, /* offline_message */ | |
| 100 | NULL, /* whiteboard_prpl_ops */ | |
| 15185 | 101 | NULL, /* send_raw */ |
| 102 | NULL, /* roomlist_room_serialize */ | |
|
22244
221f48b173e3
Update some comments in oscar's prpl callback structs
Mark Doliner <markdoliner@pidgin.im>
parents:
20288
diff
changeset
|
103 | NULL, /* unregister_user */ |
|
221f48b173e3
Update some comments in oscar's prpl callback structs
Mark Doliner <markdoliner@pidgin.im>
parents:
20288
diff
changeset
|
104 | NULL, /* send_attention */ |
|
221f48b173e3
Update some comments in oscar's prpl callback structs
Mark Doliner <markdoliner@pidgin.im>
parents:
20288
diff
changeset
|
105 | NULL, /* get_attention_types */ |
|
16746
72faf41c3c4f
And now the protocols
Gary Kramlich <grim@reaperworld.com>
parents:
15884
diff
changeset
|
106 | |
|
23276
f4944cfaa1ff
Use up the last padding for PurplePluginProtocolInfo in a way that allows
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
22244
diff
changeset
|
107 | sizeof(PurplePluginProtocolInfo), /* struct_size */ |
|
24235
46abfb2f03e4
Show 'ICQ UIN...' and 'Yahoo ID...' in the screenname field
Sadrul Habib Chowdhury <sadrul@pidgin.im>
parents:
23277
diff
changeset
|
108 | icq_get_account_text_table, /* get_account_text_table */ |
|
23707
480f94157418
propagate from branch 'im.pidgin.pidgin' (head bd5f7f61d9349053ee4738efc0d17453f0574057)
Sadrul Habib Chowdhury <sadrul@pidgin.im>
diff
changeset
|
109 | NULL, /* initiate_media */ |
| 29404 | 110 | NULL, /* can_do_media */ |
|
24912
9ae8349f0353
Move the mood UI for ICQ into Pidgin. It still uses the new request API
Richard Laager <rlaager@pidgin.im>
parents:
24235
diff
changeset
|
111 | oscar_get_purple_moods, /* get_moods */ |
|
30138
cca9685df785
Add purple_account_[gs]et_public_alias functions, per discussion in d@cpi
Paul Aurich <darkrain42@pidgin.im>
parents:
29859
diff
changeset
|
112 | NULL, /* set_public_alias */ |
|
cca9685df785
Add purple_account_[gs]et_public_alias functions, per discussion in d@cpi
Paul Aurich <darkrain42@pidgin.im>
parents:
29859
diff
changeset
|
113 | NULL /* get_public_alias */ |
| 15030 | 114 | }; |
| 115 | ||
| 15884 | 116 | static PurplePluginInfo info = |
| 15030 | 117 | { |
| 15884 | 118 | PURPLE_PLUGIN_MAGIC, |
| 119 | PURPLE_MAJOR_VERSION, | |
| 120 | PURPLE_MINOR_VERSION, | |
| 121 | PURPLE_PLUGIN_PROTOCOL, /**< type */ | |
| 15030 | 122 | NULL, /**< ui_requirement */ |
| 123 | 0, /**< flags */ | |
| 124 | NULL, /**< dependencies */ | |
| 15884 | 125 | PURPLE_PRIORITY_DEFAULT, /**< priority */ |
| 15030 | 126 | |
| 127 | "prpl-icq", /**< id */ | |
| 128 | "ICQ", /**< name */ | |
|
20288
5ca925a094e2
applied changes from 03b709ec2a153e7e82719df0ba4635108bb1d3c6
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
19859
diff
changeset
|
129 | DISPLAY_VERSION, /**< version */ |
| 15030 | 130 | /** summary */ |
| 131 | N_("ICQ Protocol Plugin"), | |
| 132 | /** description */ | |
| 133 | N_("ICQ Protocol Plugin"), | |
| 134 | NULL, /**< author */ | |
| 15884 | 135 | PURPLE_WEBSITE, /**< homepage */ |
| 15030 | 136 | |
| 137 | NULL, /**< load */ | |
| 138 | NULL, /**< unload */ | |
| 139 | NULL, /**< destroy */ | |
| 140 | ||
| 141 | NULL, /**< ui_info */ | |
| 142 | &prpl_info, /**< extra_info */ | |
| 143 | NULL, | |
|
16746
72faf41c3c4f
And now the protocols
Gary Kramlich <grim@reaperworld.com>
parents:
15884
diff
changeset
|
144 | oscar_actions, |
|
72faf41c3c4f
And now the protocols
Gary Kramlich <grim@reaperworld.com>
parents:
15884
diff
changeset
|
145 | |
|
72faf41c3c4f
And now the protocols
Gary Kramlich <grim@reaperworld.com>
parents:
15884
diff
changeset
|
146 | /* padding */ |
|
72faf41c3c4f
And now the protocols
Gary Kramlich <grim@reaperworld.com>
parents:
15884
diff
changeset
|
147 | NULL, |
|
72faf41c3c4f
And now the protocols
Gary Kramlich <grim@reaperworld.com>
parents:
15884
diff
changeset
|
148 | NULL, |
|
72faf41c3c4f
And now the protocols
Gary Kramlich <grim@reaperworld.com>
parents:
15884
diff
changeset
|
149 | NULL, |
|
72faf41c3c4f
And now the protocols
Gary Kramlich <grim@reaperworld.com>
parents:
15884
diff
changeset
|
150 | NULL |
| 15030 | 151 | }; |
| 152 | ||
| 153 | static void | |
| 15884 | 154 | init_plugin(PurplePlugin *plugin) |
| 15030 | 155 | { |
| 15884 | 156 | PurpleAccountOption *option; |
| 15030 | 157 | |
|
28817
a6c03addaccf
oscar: Remove the simultaneous logins option from ICQ accounts.
Paul Aurich <darkrain42@pidgin.im>
parents:
26482
diff
changeset
|
158 | oscar_init(plugin); |
| 15030 | 159 | |
| 15884 | 160 | option = purple_account_option_string_new(_("Encoding"), "encoding", OSCAR_DEFAULT_CUSTOM_ENCODING); |
| 15030 | 161 | prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option); |
| 162 | } | |
| 163 | ||
| 15884 | 164 | PURPLE_INIT_PLUGIN(icq, init_plugin, info); |