aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main.c5
-rw-r--r--src/plugin.c35
-rw-r--r--src/plugin.h11
3 files changed, 51 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c
index 2292a0cf..c3368a29 100644
--- a/src/main.c
+++ b/src/main.c
@@ -1232,6 +1232,11 @@ static void plugin_init(void)
ADD_SYM(alertpanel_message);
ADD_SYM(alertpanel_message_with_disable);
+ ADD_SYM(send_message);
+ ADD_SYM(send_message_queue_all);
+ ADD_SYM(send_message_set_reply_flag);
+ ADD_SYM(send_message_set_forward_flags);
+
syl_plugin_signal_connect("plugin-load", G_CALLBACK(load_cb), NULL);
/* loading plug-ins from user plug-in directory */
diff --git a/src/plugin.c b/src/plugin.c
index 2c6b1a2d..baead872 100644
--- a/src/plugin.c
+++ b/src/plugin.c
@@ -1142,3 +1142,38 @@ gint syl_plugin_alertpanel_message_with_disable(const gchar *title,
GETFUNC("alertpanel_message_with_disable");
return SAFE_CALL_ARG3_RET_VAL(func, title, message, type, 0);
}
+
+gint syl_plugin_send_message(const gchar *file, PrefsAccount *ac,
+ GSList *to_list)
+{
+ gint (*func)(const gchar *, PrefsAccount *, GSList *);
+
+ GETFUNC("send_message");
+ return SAFE_CALL_ARG3_RET_VAL(func, file, ac, to_list, -1);
+}
+
+gint syl_plugin_send_message_queue_all(FolderItem *queue, gboolean save_msgs,
+ gboolean filter_msgs)
+{
+ gint (*func)(FolderItem *, gboolean, gboolean);
+
+ GETFUNC("send_message_queue_all");
+ return SAFE_CALL_ARG3_RET_VAL(func, queue, save_msgs, filter_msgs, -1);
+}
+
+gint syl_plugin_send_message_set_reply_flag(const gchar *reply_target,
+ const gchar *msgid)
+{
+ gint (*func)(const gchar *, const gchar *);
+
+ GETFUNC("send_message_set_reply_flag");
+ return SAFE_CALL_ARG2_RET_VAL(func, reply_target, msgid, -1);
+}
+
+gint syl_plugin_send_message_set_forward_flags(const gchar *forward_targets)
+{
+ gint (*func)(const gchar *);
+
+ GETFUNC("send_message_set_forward_flags");
+ return SAFE_CALL_ARG1_RET_VAL(func, forward_targets, -1);
+}
diff --git a/src/plugin.h b/src/plugin.h
index 23bbb485..4d0ea5df 100644
--- a/src/plugin.h
+++ b/src/plugin.h
@@ -271,4 +271,15 @@ gint syl_plugin_alertpanel_message_with_disable (const gchar *title,
const gchar *message,
gint type);
+/* Send message */
+gint syl_plugin_send_message (const gchar *file,
+ PrefsAccount *ac,
+ GSList *to_list);
+gint syl_plugin_send_message_queue_all (FolderItem *queue,
+ gboolean save_msgs,
+ gboolean filter_msgs);
+gint syl_plugin_send_message_set_reply_flag (const gchar *reply_target,
+ const gchar *msgid);
+gint syl_plugin__send_message_set_forward_flags (const gchar *forward_targets);
+
#endif /* __PLUGIN_H__ */