diff options
author | George Hazan <george.hazan@gmail.com> | 2024-04-17 20:00:05 +0300 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2024-04-17 20:00:05 +0300 |
commit | 366b12a36bf052025bce085d2859486e0318231c (patch) | |
tree | 7f6aee056041cd2892ed120a74aacc8206969351 /include | |
parent | 59a8c98ac4f4b208a27eed43cc860c8e5a9c799b (diff) |
db_event_delivered + ME_DB_EVENT_DELIVERED = helper & hookable event to catch event's delivery to a server
Diffstat (limited to 'include')
-rw-r--r-- | include/m_database.h | 14 | ||||
-rw-r--r-- | include/m_db_int.h | 7 |
2 files changed, 18 insertions, 3 deletions
diff --git a/include/m_database.h b/include/m_database.h index 75c34d2dbb..5dd0a2859a 100644 --- a/include/m_database.h +++ b/include/m_database.h @@ -298,6 +298,10 @@ EXTERN_C MIR_CORE_DLL(int) db_event_count(MCONTACT hContact); EXTERN_C MIR_CORE_DLL(int) db_event_delete(MEVENT hDbEvent, int flags = 0);
+// Marks our own event as delivered
+
+EXTERN_C MIR_CORE_DLL(int) db_event_delivered(MCONTACT hContact, MEVENT hDbEvent);
+
// Edits an event in the database
// Returns 0 on success, or nonzero on error
@@ -613,6 +617,16 @@ EXTERN_C MIR_APP_DLL(HICON) DbEvent_GetIcon(DBEVENTINFO *dbei, int flags); #define ME_DB_EVENT_DELETED "DB/Event/Deleted"
/////////////////////////////////////////////////////////////////////////////////////////
+// DB/Event/Delivered event
+// Called when the server confirms that an event was successfully delivered to server
+// wParam = (MCONTACT)hContact
+// lParam = (LPARAM)(HANDLE)hDbEvent
+// hDbEvent is a valid handle to the event.
+// hContact is a valid handle to the contact to which hDbEvent refers, and will remain valid.
+
+#define ME_DB_EVENT_DELIVERED "DB/Event/Delivered"
+
+/////////////////////////////////////////////////////////////////////////////////////////
// DB/Contact/Added event
// Called when a new contact has been added to the database
// wParam = (MCONTACT)hContact
diff --git a/include/m_db_int.h b/include/m_db_int.h index 1657a13d05..51f494049a 100644 --- a/include/m_db_int.h +++ b/include/m_db_int.h @@ -378,12 +378,13 @@ struct DATABASELINK EXTERN_C MIR_APP_EXPORT HANDLE
g_hevContactDeleted, // ME_DB_CONTACT_DELETED
- g_hevContactAdded, // ME_DB_CONTACT_ADDED
+ g_hevContactAdded, // ME_DB_CONTACT_ADDED
g_hevSettingChanged, // ME_DB_CONTACT_SETTINGCHANGED
g_hevMarkedRead, // ME_DB_EVENT_MARKED_READ
- g_hevEventAdded, // ME_DB_EVENT_ADDED
- g_hevEventEdited, // ME_DB_EVENT_EDITED
+ g_hevEventAdded, // ME_DB_EVENT_ADDED
+ g_hevEventEdited, // ME_DB_EVENT_EDITED
g_hevEventDeleted, // ME_DB_EVENT_DELETED
+ g_hevEventDelivered, // ME_DB_EVENT_DELIVERED
g_hevEventFiltered; // ME_DB_EVENT_FILTER_ADD
/////////////////////////////////////////////////////////////////////////////////////////
|