libpurple/protocols/yahoo/libyahoojp.c

Sun, 05 Jul 2009 14:14:14 +0000

author
John Bailey <rekkanoryo@rekkanoryo.org>
date
Sun, 05 Jul 2009 14:14:14 +0000
branch
cpw.rekkanoryo.yahoo.separate_prpls
changeset 27557
08a8cbc0a0ec
parent 27556
3daffa5f82dd
child 27559
3007dde24778
permissions
-rw-r--r--

have a separate hash table function for each prpl.

27556
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
1 /*
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
2 * purple
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
3 *
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
4 * Purple is the legal property of its developers, whose names are too numerous
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
5 * to list here. Please refer to the COPYRIGHT file distributed with this
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
6 * source distribution.
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
7 *
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
8 * This program is free software; you can redistribute it and/or modify
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
9 * it under the terms of the GNU General Public License as published by
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
10 * the Free Software Foundation; either version 2 of the License, or
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
11 * (at your option) any later version.
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
12 *
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
13 * This program is distributed in the hope that it will be useful,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
16 * GNU General Public License for more details.
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
17 *
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
18 * You should have received a copy of the GNU General Public License
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
19 * along with this program; if not, write to the Free Software
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
20 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
21 *
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
22 */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
23
27557
08a8cbc0a0ec have a separate hash table function for each prpl.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 27556
diff changeset
24 static GHashTable *
08a8cbc0a0ec have a separate hash table function for each prpl.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 27556
diff changeset
25 yahoojp_get_account_text_table(PurpleAccount *account)
08a8cbc0a0ec have a separate hash table function for each prpl.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 27556
diff changeset
26 {
08a8cbc0a0ec have a separate hash table function for each prpl.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 27556
diff changeset
27 GHashTable *table;
08a8cbc0a0ec have a separate hash table function for each prpl.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 27556
diff changeset
28 table = g_hash_table_new(g_str_hash, g_str_equal);
08a8cbc0a0ec have a separate hash table function for each prpl.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 27556
diff changeset
29 g_hash_table_insert(table, "login_label", (gpointer)_("Yahoo JAPAN ID..."));
08a8cbc0a0ec have a separate hash table function for each prpl.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 27556
diff changeset
30 return table;
08a8cbc0a0ec have a separate hash table function for each prpl.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 27556
diff changeset
31 }
08a8cbc0a0ec have a separate hash table function for each prpl.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 27556
diff changeset
32
27556
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
33 static PurpleWhiteboardPrplOps yahoo_whiteboard_prpl_ops =
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
34 {
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
35 yahoo_doodle_start,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
36 yahoo_doodle_end,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
37 yahoo_doodle_get_dimensions,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
38 NULL,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
39 yahoo_doodle_get_brush,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
40 yahoo_doodle_set_brush,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
41 yahoo_doodle_send_draw_list,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
42 yahoo_doodle_clear,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
43
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
44 /* padding */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
45 NULL,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
46 NULL,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
47 NULL,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
48 NULL
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
49 };
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
50
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
51 static PurplePluginProtocolInfo prpl_info =
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
52 {
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
53 OPT_PROTO_MAIL_CHECK | OPT_PROTO_CHAT_TOPIC,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
54 NULL, /* user_splits */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
55 NULL, /* protocol_options */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
56 {"png,gif,jpeg", 96, 96, 96, 96, 0, PURPLE_ICON_SCALE_SEND},
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
57 yahoo_list_icon,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
58 yahoo_list_emblem,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
59 yahoo_status_text,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
60 yahoo_tooltip_text,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
61 yahoo_status_types,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
62 yahoo_blist_node_menu,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
63 yahoo_c_info,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
64 yahoo_c_info_defaults,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
65 yahoo_login,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
66 yahoo_close,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
67 yahoo_send_im,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
68 NULL, /* set info */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
69 yahoo_send_typing,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
70 yahoo_get_info,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
71 yahoo_set_status,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
72 yahoo_set_idle,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
73 NULL, /* change_passwd*/
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
74 yahoo_add_buddy,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
75 NULL, /* add_buddies */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
76 yahoo_remove_buddy,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
77 NULL, /* remove_buddies */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
78 NULL, /* add_permit */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
79 yahoo_add_deny,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
80 NULL, /* rem_permit */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
81 yahoo_rem_deny,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
82 yahoo_set_permit_deny,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
83 yahoo_c_join,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
84 NULL, /* reject chat invite */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
85 yahoo_get_chat_name,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
86 yahoo_c_invite,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
87 yahoo_c_leave,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
88 NULL, /* chat whisper */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
89 yahoo_c_send,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
90 yahoo_keepalive,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
91 NULL, /* register_user */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
92 NULL, /* get_cb_info */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
93 NULL, /* get_cb_away */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
94 yahoo_update_alias, /* alias_buddy */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
95 yahoo_change_buddys_group,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
96 yahoo_rename_group,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
97 NULL, /* buddy_free */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
98 NULL, /* convo_closed */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
99 purple_normalize_nocase, /* normalize */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
100 yahoo_set_buddy_icon,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
101 NULL, /* void (*remove_group)(PurpleConnection *gc, const char *group);*/
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
102 NULL, /* char *(*get_cb_real_name)(PurpleConnection *gc, int id, const char *who); */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
103 NULL, /* set_chat_topic */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
104 NULL, /* find_blist_chat */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
105 yahoo_roomlist_get_list,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
106 yahoo_roomlist_cancel,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
107 yahoo_roomlist_expand_category,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
108 NULL, /* can_receive_file */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
109 yahoo_send_file,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
110 yahoo_new_xfer,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
111 yahoo_offline_message, /* offline_message */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
112 &yahoo_whiteboard_prpl_ops,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
113 NULL, /* send_raw */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
114 NULL, /* roomlist_room_serialize */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
115 NULL, /* unregister_user */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
116
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
117 yahoo_send_attention,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
118 yahoo_attention_types,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
119
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
120 sizeof(PurplePluginProtocolInfo), /* struct_size */
27557
08a8cbc0a0ec have a separate hash table function for each prpl.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 27556
diff changeset
121 yahoojp_get_account_text_table, /* get_account_text_table */
27556
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
122 NULL, /* initiate_media */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
123 NULL /* can_do_media */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
124 };
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
125
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
126 static PurplePluginInfo info =
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
127 {
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
128 PURPLE_PLUGIN_MAGIC,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
129 PURPLE_MAJOR_VERSION,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
130 PURPLE_MINOR_VERSION,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
131 PURPLE_PLUGIN_PROTOCOL, /**< type */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
132 NULL, /**< ui_requirement */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
133 0, /**< flags */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
134 NULL, /**< dependencies */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
135 PURPLE_PRIORITY_DEFAULT, /**< priority */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
136 "prpl-yahoojp", /**< id */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
137 "Yahoo JAPAN", /**< name */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
138 DISPLAY_VERSION, /**< version */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
139 /** summary */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
140 N_("Yahoo JAPAN Protocol Plugin"),
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
141 /** description */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
142 N_("Yahoo JAPAN Protocol Plugin"),
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
143 NULL, /**< author */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
144 PURPLE_WEBSITE, /**< homepage */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
145 NULL, /**< load */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
146 yahoo_unload_plugin, /**< unload */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
147 NULL, /**< destroy */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
148 NULL, /**< ui_info */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
149 &prpl_info, /**< extra_info */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
150 NULL,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
151 yahoo_actions,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
152
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
153 /* padding */
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
154 NULL,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
155 NULL,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
156 NULL,
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
157 NULL
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
158 };
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
159
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
160 static void
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
161 init_plugin(PurplePlugin *plugin)
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
162 {
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
163 PurpleAccountOption *option;
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
164
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
165 option = purple_account_option_string_new(_("Pager server"), "server", YAHOOJP_PAGER_HOST);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
166 prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
167
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
168 option = purple_account_option_int_new(_("Pager port"), "port", YAHOO_PAGER_PORT);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
169 prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
170
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
171 option = purple_account_option_string_new(_("File transfer server"), "xfer_host", YAHOOJP_XFER_HOST);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
172 prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
173
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
174 option = purple_account_option_int_new(_("File transfer port"), "xfer_port", YAHOO_XFER_PORT);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
175 prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
176
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
177 option = purple_account_option_string_new(_("Chat room locale"), "room_list_locale", YAHOOJP_ROOMLIST_LOCALE);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
178 prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
179
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
180 option = purple_account_option_bool_new(_("Ignore conference and chatroom invitations"), "ignore_invites", FALSE);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
181 prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
182
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
183 option = purple_account_option_string_new(_("Encoding"), "local_charset", "UTF-8");
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
184 prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
185
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
186
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
187 #if 0
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
188 option = purple_account_option_string_new(_("Chat room list URL"), "room_list", YAHOO_ROOMLIST_URL);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
189 prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
190
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
191 option = purple_account_option_string_new(_("Yahoo Chat server"), "ycht-server", YAHOO_YCHT_HOST);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
192 prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
193
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
194 option = purple_account_option_int_new(_("Yahoo Chat port"), "ycht-port", YAHOO_YCHT_PORT);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
195 prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
196 #endif
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
197
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
198 my_protocol = plugin;
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
199 yahoopurple_register_commands();
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
200 yahoo_init_colorht();
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
201 }
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
202
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
203 PURPLE_INIT_PLUGIN(yahoojp, init_plugin, info);
3daffa5f82dd Very rudimentary start to separate prpls. Removed URI handler from the
John Bailey <rekkanoryo@rekkanoryo.org>
parents:
diff changeset
204

mercurial