Call the listeners if a new ack might need to be sent.

This commit is contained in:
akwizgran
2011-10-14 18:29:14 +01:00
parent d48c7b6900
commit e00e12d473
2 changed files with 2 additions and 0 deletions

View File

@@ -4,6 +4,7 @@ package net.sf.briar.api.db;
public interface DatabaseListener {
static enum Event {
ACKS_ADDED,
CONTACTS_UPDATED,
MESSAGES_ADDED,
SUBSCRIPTIONS_UPDATED,

View File

@@ -937,6 +937,7 @@ DatabaseCleaner.Callback {
contactLock.readLock().unlock();
}
// Call the listeners outside the lock
callListeners(Event.ACKS_ADDED);
if(anyAdded) callListeners(Event.MESSAGES_ADDED);
}