comparison pidgin-twitter.h @ 95:ab612180e7d0

- added identica support. linkfy and character counter work. icon support has not implemented yet. - put common code together.
author Yoshiki Yazawa <yaz@honeyplanet.jp>
date Thu, 10 Jul 2008 00:12:03 +0900
parents 31cddb2c2acc
children 24ad534e438e
comparison
equal deleted inserted replaced
94:31cddb2c2acc 95:ab612180e7d0
46 #define OPT_API_BASE_POST OPT_PIDGINTWITTER "/api_base_post" 46 #define OPT_API_BASE_POST OPT_PIDGINTWITTER "/api_base_post"
47 #define OPT_SCREEN_NAME OPT_PIDGINTWITTER "/screen_name" 47 #define OPT_SCREEN_NAME OPT_PIDGINTWITTER "/screen_name"
48 #define OPT_PASSWORD OPT_PIDGINTWITTER "/password" 48 #define OPT_PASSWORD OPT_PIDGINTWITTER "/password"
49 49
50 /* formats and templates */ 50 /* formats and templates */
51 #define RECIPIENT_FORMAT "@<a href='http://twitter.com/%s'>%s</a>" 51 #define RECIPIENT_FORMAT_TWITTER "@<a href='http://twitter.com/%s'>%s</a>"
52 #define SENDER_FORMAT "%s<a href='http://twitter.com/%s'>%s</a>: " 52 #define SENDER_FORMAT_TWITTER "%s<a href='http://twitter.com/%s'>%s</a>: "
53 #define RECIPIENT_FORMAT_WASSR "@<a href='http://wassr.jp/user/%s'>%s</a>" 53 #define RECIPIENT_FORMAT_WASSR "@<a href='http://wassr.jp/user/%s'>%s</a>"
54 #define SENDER_FORMAT_WASSR "%s<a href='http://wassr.jp/user/%s'>%s</a>: " 54 #define SENDER_FORMAT_WASSR "%s<a href='http://wassr.jp/user/%s'>%s</a>: "
55 #define RECIPIENT_FORMAT_IDENTICA "@<a href='http://identi.ca/%s'>%s</a>"
56 #define SENDER_FORMAT_IDENTICA "%s<a href='http://identi.ca/%s'>%s</a>: "
55 #define DEFAULT_LIST "(list of users: separated with ' ,:;')" 57 #define DEFAULT_LIST "(list of users: separated with ' ,:;')"
56 #define OOPS_MESSAGE "<body>Oops! Your update was over 140 characters. We sent the short version to your friends (they can view the entire update on the web).<BR></body>" 58 #define OOPS_MESSAGE "<body>Oops! Your update was over 140 characters. We sent the short version to your friends (they can view the entire update on the web).<BR></body>"
57 #define EMPTY "" 59 #define EMPTY ""
58 60
59 /* patterns */ 61 /* patterns */
85 static void attach_to_conv(PurpleConversation *conv, gpointer null); 87 static void attach_to_conv(PurpleConversation *conv, gpointer null);
86 static gboolean is_twitter_account(PurpleAccount *account, const char *name); 88 static gboolean is_twitter_account(PurpleAccount *account, const char *name);
87 static gboolean is_twitter_conv(PurpleConversation *conv); 89 static gboolean is_twitter_conv(PurpleConversation *conv);
88 static gboolean is_wassr_account(PurpleAccount *account, const char *name); 90 static gboolean is_wassr_account(PurpleAccount *account, const char *name);
89 static gboolean is_wassr_conv(PurpleConversation *conv); 91 static gboolean is_wassr_conv(PurpleConversation *conv);
92 static gboolean is_identica_account(PurpleAccount *account, const char *name);
93 static gboolean is_identica_conv(PurpleConversation *conv);
90 static void conv_created_cb(PurpleConversation *conv, gpointer null); 94 static void conv_created_cb(PurpleConversation *conv, gpointer null);
91 static void deleting_conv_cb(PurpleConversation *conv); 95 static void deleting_conv_cb(PurpleConversation *conv);
92 static gboolean receiving_im_cb(PurpleAccount *account, char **sender, char **buffer, PurpleConversation *conv, PurpleMessageFlags *flags, void *data); 96 static gboolean receiving_im_cb(PurpleAccount *account, char **sender, char **buffer, PurpleConversation *conv, PurpleMessageFlags *flags, void *data);
93 static void insert_icon_at_mark(GtkTextMark *requested_mark, gpointer user_data); 97 static void insert_icon_at_mark(GtkTextMark *requested_mark, gpointer user_data);
94 static void insert_requested_icon(const gchar *user_name, gint service); 98 static void insert_requested_icon(const gchar *user_name, gint service);