Mercurial > pidgin
diff libpurple/protocols/qq/im.h @ 24643:d2d6fff831dc
Add some new function define
author | Hu Yong <ccpaging@gmail.com> |
---|---|
date | Wed, 19 Nov 2008 08:35:32 +0000 |
parents | 7aecbc973329 |
children | d8452c0bec7b |
line wrap: on
line diff
--- a/libpurple/protocols/qq/im.h Wed Nov 19 08:35:07 2008 +0000 +++ b/libpurple/protocols/qq/im.h Wed Nov 19 08:35:32 2008 +0000 @@ -33,7 +33,7 @@ QQ_MSG_TO_UNKNOWN = 0x000a, QQ_MSG_SMS = 0x0014, /* not sure */ QQ_MSG_NEWS = 0x0018, - QQ_MSG_UNKNOWN_QUN_IM = 0x0020, + QQ_MSG_QUN_IM_UNKNOWN = 0x0020, QQ_MSG_ADD_TO_QUN = 0x0021, QQ_MSG_DEL_FROM_QUN = 0x0022, QQ_MSG_APPLY_ADD_TO_QUN = 0x0023, @@ -49,17 +49,22 @@ }; typedef struct { + guint8 attr; + guint8 rgb[3]; + guint16 charset; gchar *font; /* Attension: font may NULL. font name is in QQ charset */ guint8 font_len; - guint8 attr; - guint8 rgb[3]; } qq_im_format; -qq_im_format *qq_im_fmt_new_by_purple(const gchar *msg); -gboolean qq_im_smiley_none(const gchar *msg); +gint qq_put_im_tail(guint8 *buf, qq_im_format *fmt); +gint qq_get_im_tail(qq_im_format *fmt, guint8 *data, gint data_len); + +qq_im_format *qq_im_fmt_new(void); void qq_im_fmt_free(qq_im_format *fmt); +qq_im_format *qq_im_fmt_new_by_purple(const gchar *msg); +gchar *qq_im_fmt_to_purple(qq_im_format *fmt, gchar *text); +gboolean qq_im_smiley_none(const gchar *msg); GSList *qq_im_get_segments(gchar *msg_stripped, gboolean is_smiley_none); -gint qq_put_im_tail(guint8 *buf, qq_im_format *fmt); void qq_got_message(PurpleConnection *gc, const gchar *msg); gint qq_send_im(PurpleConnection *gc, const gchar *who, const gchar *message, PurpleMessageFlags flags); @@ -68,5 +73,4 @@ void qq_process_extend_im(PurpleConnection *gc, guint8 *data, gint len); gchar *qq_emoticon_to_purple(gchar *text); -gchar *qq_format_to_purple(guint8 *data, gint len, gchar *text); #endif