2012-02-02 [pawel] 3.8.0cvs21
[claws.git] / src / procmsg.h
index 70049661efe26ad09439dda86ccd6ce5f1d57af8..859d1c56e503734d5673afd266bcc1d26c2a500d 100644 (file)
@@ -1,6 +1,6 @@
 /*
  * Sylpheed -- a GTK+ based, lightweight, and fast e-mail client
- * Copyright (C) 1999-2007 Hiroyuki Yamamoto and the Claws Mail team
+ * Copyright (C) 1999-2011 Hiroyuki Yamamoto and the Claws Mail team
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -29,6 +29,7 @@
 #include <time.h>
 #include <sys/types.h>
 #include <string.h>
+#include "utils.h"
 
 typedef struct _MsgInfo                        MsgInfo;
 typedef struct _MsgFlags               MsgFlags;
@@ -173,7 +174,8 @@ typedef guint32 MsgTmpFlags;
 
 typedef enum {
        MSGINFO_UPDATE_FLAGS = 1 << 0,
-       MSGINFO_UPDATE_DELETED = 1 << 1
+       MSGINFO_UPDATE_DELETED = 1 << 1,
+       MSGINFO_UPDATE_ADDED = 1 << 2
 } MsgInfoUpdateFlags;
 
 #include "procmime.h"
@@ -205,7 +207,7 @@ struct _MsgInfo
        guint refcnt;
 
        guint  msgnum;
-       off_t  size;
+       goffset  size;
        time_t mtime;
        time_t date_t;
        time_t thread_date;
@@ -329,6 +331,8 @@ void        procmsg_empty_all_trash         (void);
 gint   procmsg_send_queue              (FolderItem     *queue,
                                         gboolean        save_msgs,
                                         gchar          **errstr);
+gboolean procmsg_queue_lock            (gchar          **errstr);
+void     procmsg_queue_unlock          (void);
 gboolean procmsg_queue_is_empty        (FolderItem *queue);
 void   procmsg_print_message           (MsgInfo        *msginfo,
                                         const gchar    *cmdline);
@@ -343,6 +347,12 @@ MsgInfo *procmsg_msginfo_get_full_info_from_file
 void    procmsg_msginfo_free           (MsgInfo        *msginfo);
 guint   procmsg_msginfo_memusage       (MsgInfo        *msginfo);
 
+gint procmsg_send_message_queue_with_lock(const gchar *file,
+                                         gchar **errstr,
+                                         FolderItem *queue,
+                                         gint msgnum,
+                                         gboolean *queued_removed);
+
 gint procmsg_send_message_queue                (const gchar *file,
                                         gchar **errstr,
                                         FolderItem *queue,