aboutsummaryrefslogtreecommitdiffstats
path: root/src/messaging/IMAPFolder.cpp
diff options
context:
space:
mode:
authorVincent Richard <[email protected]>2004-12-21 10:19:22 +0000
committerVincent Richard <[email protected]>2004-12-21 10:19:22 +0000
commitbf2c7776918cf4cd981da3f31332e0e0475b27de (patch)
tree869f62c97b33b8d99249d60e2b0f5b017bb5ba90 /src/messaging/IMAPFolder.cpp
parentFixed ',2' in filename/flags + fixed file renaming when moving from 'new' to ... (diff)
downloadvmime-bf2c7776918cf4cd981da3f31332e0e0475b27de.tar.gz
vmime-bf2c7776918cf4cd981da3f31332e0e0475b27de.zip
Fixed notification when adding message to IMAP folder.
Diffstat (limited to 'src/messaging/IMAPFolder.cpp')
-rw-r--r--src/messaging/IMAPFolder.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/messaging/IMAPFolder.cpp b/src/messaging/IMAPFolder.cpp
index 8d1b9a8e..a3c83c77 100644
--- a/src/messaging/IMAPFolder.cpp
+++ b/src/messaging/IMAPFolder.cpp
@@ -1154,6 +1154,19 @@ void IMAPFolder::addMessage(utility::inputStream& is, const int size, const int
m_messageCount++;
notifyMessageCount(event);
+
+ // Notify folders with the same path
+ for (std::list <IMAPFolder*>::iterator it = m_store->m_folders.begin() ;
+ it != m_store->m_folders.end() ; ++it)
+ {
+ if ((*it) != this && (*it)->getFullPath() == m_path)
+ {
+ events::messageCountEvent event(*it, events::messageCountEvent::TYPE_ADDED, nums);
+
+ (*it)->m_messageCount++;
+ (*it)->notifyMessageCount(event);
+ }
+ }
}