* Removed an invalid separator in the File menu
[modest] / src / modest-mail-operation.h
index 8f0baa7..57ddd58 100644 (file)
@@ -71,9 +71,10 @@ typedef enum _ModestMailOperationReplyMode {
 typedef enum _ModestMailOperationStatus {
        MODEST_MAIL_OPERATION_STATUS_INVALID,
        MODEST_MAIL_OPERATION_STATUS_SUCCESS,
+       MODEST_MAIL_OPERATION_STATUS_FINISHED_WITH_ERRORS,
        MODEST_MAIL_OPERATION_STATUS_FAILED,
        MODEST_MAIL_OPERATION_STATUS_IN_PROGRESS,
-       MODEST_MAIL_OPERATION_STATUS_CANCELLED
+       MODEST_MAIL_OPERATION_STATUS_CANCELED
 } ModestMailOperationStatus;
 
 struct _ModestMailOperation {
@@ -83,8 +84,9 @@ struct _ModestMailOperation {
 
 struct _ModestMailOperationClass {
        GObjectClass parent_class;
-       /* insert signal callback declarations, eg. */
-       /* void (* my_event) (ModestMailOperation* obj); */
+
+       /* Signals */
+       void (*progress_changed) (ModestMailOperation *mail_op, gpointer user_data);
 };
 
 /* member functions */
@@ -117,7 +119,7 @@ TnyMsg* modest_mail_operation_create_reply_mail    (TnyMsg *msg,
                                                    ModestMailOperationReplyType reply_type,
                                                    ModestMailOperationReplyMode reply_mode);
 
-void    modest_mail_operation_update_account       (ModestMailOperation *mail_op,
+gboolean      modest_mail_operation_update_account (ModestMailOperation *mail_op,
                                                    TnyStoreAccount *store_account);
 
 /* Functions that perform store operations */
@@ -156,11 +158,18 @@ void          modest_mail_operation_remove_msg     (ModestMailOperation *mail_op
                                                    gboolean remove_to_trash);
 
 /* Functions to control mail operations */
-ModestMailOperationStatus modest_mail_operation_get_status (ModestMailOperation *mail_op);
+guint     modest_mail_operation_get_task_done      (ModestMailOperation *mail_op);
+
+guint     modest_mail_operation_get_task_total     (ModestMailOperation *mail_op);
+
+
+gboolean                  modest_mail_operation_is_finished (ModestMailOperation *mail_op);
+
+ModestMailOperationStatus modest_mail_operation_get_status  (ModestMailOperation *mail_op);
 
-const GError*             modest_mail_operation_get_error  (ModestMailOperation *mail_op);
+const GError*             modest_mail_operation_get_error   (ModestMailOperation *mail_op);
 
-void                      modest_mail_operation_cancel     (ModestMailOperation *mail_op);
+void                      modest_mail_operation_cancel      (ModestMailOperation *mail_op);
 
 G_END_DECLS