Patch to improve priority flags management
- From: jfernandez <jfernandez igalia com>
- To: tinymail-devel-list gnome org
- Subject: Patch to improve priority flags management
- Date: Mon, 23 Apr 2007 10:02:28 +0200
Hi,
I tried to implement a bit improvement of priority flags definition.
A single flag replace the old 3 flags HIGH, NORMAL, LOW. This new flag will
be called PRIORITY_FLAGS and will be set to 1<<10|1<<9 to be used as bit mask.
A new enumeration is defined, TnyHeaderPriorityFlags, with all available priority
levels.
Greetings,
--
Javier Fernández García-Boente
Ingeniero en Informática
mailto:jfernandez igalia com
Igalia http://www.igalia.com
Telf. +34 981 91 39 91
Fax. +34 981 91 39 49
Index: libtinymail/tny-shared.h
===================================================================
--- libtinymail/tny-shared.h (revisión: 1825)
+++ libtinymail/tny-shared.h (copia de trabajo)
@@ -55,6 +55,7 @@
typedef void (*TnyTransferMsgsCallback) (TnyFolder *folder, GError **err, gpointer user_data);
typedef void (*TnyStatusCallback) (gpointer self, const gchar *what, gint sofar, gint oftotal, gpointer user_data);
typedef enum _TnyHeaderFlags TnyHeaderFlags;
+typedef enum _TnyHeaderPriorityFlags TnyHeaderPriorityFlags;
typedef enum _TnyAlertType TnyAlertType;
typedef enum _TnyFolderType TnyFolderType;
typedef struct _TnySimpleList TnySimpleList;
Index: libtinymail/tny-header.h
===================================================================
--- libtinymail/tny-header.h (revisión: 1825)
+++ libtinymail/tny-header.h (copia de trabajo)
@@ -49,6 +49,7 @@
typedef struct _TnyHeader TnyHeader;
typedef struct _TnyHeaderIface TnyHeaderIface;
typedef enum _TnyHeaderFlags TnyHeaderFlags;
+typedef enum _TnyHeaderPriorityFlags TnyHeaderPriorityFlags;
#endif
enum _TnyHeaderFlags
@@ -62,14 +63,17 @@
TNY_HEADER_FLAG_CACHED = 1<<6,
TNY_HEADER_FLAG_PARTIAL = 1<<7,
TNY_HEADER_FLAG_EXPUNGED = 1<<8,
+ TNY_HEADER_FLAG_PRIORITY = 1<<9|1<<10,
+ /* Keep below 1<<12 (internally used bits) */
+};
+
+enum _TnyHeaderPriorityFlags
+{
TNY_HEADER_FLAG_HIGH_PRIORITY = 1<<9|1<<10,
TNY_HEADER_FLAG_NORMAL_PRIORITY = 0<<9|0<<10,
TNY_HEADER_FLAG_LOW_PRIORITY = 0<<9|1<<10
-
- /* Keep below 1<<12 (internally used bits) */
};
-
struct _TnyHeaderIface
{
GTypeInterface g;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]