src/protocols/zephyr/zephyr.c

changeset 5205
242b8aa81328
parent 5202
2c78987f497b
child 5234
8320a1cb0274
equal deleted inserted replaced
5204:deed98aa3181 5205:242b8aa81328
948 static const char *zephyr_list_icon(struct gaim_account *a, struct buddy *b) 948 static const char *zephyr_list_icon(struct gaim_account *a, struct buddy *b)
949 { 949 {
950 return "zephyr"; 950 return "zephyr";
951 } 951 }
952 952
953 static struct prpl *my_protocol = NULL; 953 static GaimPlugin *my_protocol = NULL;
954 954
955 void zephyr_init(struct prpl *ret) 955 static GaimPluginProtocolInfo prpl_info =
956 { 956 {
957 ret->protocol = PROTO_ZEPHYR; 957 GAIM_PROTO_ZEPHYR,
958 ret->options = OPT_PROTO_NO_PASSWORD; 958 OPT_PROTO_NO_PASSWORD,
959 ret->name = g_strdup("Zephyr"); 959 NULL,
960 ret->list_icon = zephyr_list_icon; 960 NULL,
961 ret->login = zephyr_login; 961 zephyr_list_icon,
962 ret->close = zephyr_close; 962 NULL,
963 ret->add_buddy = zephyr_add_buddy; 963 NULL,
964 ret->remove_buddy = zephyr_remove_buddy; 964 NULL,
965 ret->send_im = zephyr_send_im; 965 zephyr_away_states,
966 ret->get_info = zephyr_zloc; 966 NULL,
967 ret->normalize = zephyr_normalize; 967 zephyr_buddy_menu,
968 ret->buddy_menu = zephyr_buddy_menu; 968 zephyr_chat_info,
969 ret->away_states = zephyr_away_states; 969 zephyr_login,
970 ret->set_away = zephyr_set_away; 970 zephyr_close,
971 ret->chat_info = zephyr_chat_info; 971 zephyr_send_im,
972 ret->join_chat = zephyr_join_chat; 972 NULL,
973 ret->chat_send = zephyr_chat_send; 973 NULL,
974 ret->chat_leave = zephyr_chat_leave; 974 zephyr_zloc,
975 975 zephyr_set_away,
976 my_protocol = ret; 976 NULL,
977 } 977 NULL,
978 978 NULL,
979 #ifndef STATIC 979 NULL,
980 980 NULL,
981 G_MODULE_EXPORT void gaim_prpl_init(struct prpl *prpl) 981 NULL,
982 { 982 zephyr_add_buddy,
983 zephyr_init(prpl); 983 NULL,
984 prpl->plug->desc.api_version = PLUGIN_API_VERSION; 984 zephyr_remove_buddy,
985 } 985 NULL,
986 986 NULL,
987 987 NULL,
988 #endif 988 NULL,
989 NULL,
990 NULL,
991 NULL,
992 zephyr_join_chat,
993 NULL,
994 zephyr_chat_leave,
995 NULL,
996 zephyr_chat_send,
997 NULL,
998 NULL,
999 NULL,
1000 NULL,
1001 NULL,
1002 NULL,
1003 NULL,
1004 NULL,
1005 NULL,
1006 zephyr_normalize
1007 };
1008
1009 static GaimPluginInfo info =
1010 {
1011 2, /**< api_version */
1012 GAIM_PLUGIN_PROTOCOL, /**< type */
1013 NULL, /**< ui_requirement */
1014 0, /**< flags */
1015 NULL, /**< dependencies */
1016 GAIM_PRIORITY_DEFAULT, /**< priority */
1017
1018 "prpl-zephyr", /**< id */
1019 "Zephyr", /**< name */
1020 VERSION, /**< version */
1021 /** summary */
1022 N_("Zephyr Protocol Plugin"),
1023 /** description */
1024 N_("Zephyr Protocol Plugin"),
1025 NULL, /**< author */
1026 WEBSITE, /**< homepage */
1027
1028 NULL, /**< load */
1029 NULL, /**< unload */
1030 NULL, /**< destroy */
1031
1032 NULL, /**< ui_info */
1033 &prpl_info /**< extra_info */
1034 };
1035
1036 static void
1037 __init_plugin(GaimPlugin *plugin)
1038 {
1039 my_protocol = plugin;
1040 }
1041
1042 GAIM_INIT_PLUGIN(zephyr, __init_plugin, info);

mercurial