diff -r 139d4b7b2938 -r 99bcbff212ad emailservices/nmailagent/inc/nmmailagent.h --- a/emailservices/nmailagent/inc/nmmailagent.h Mon May 24 21:02:02 2010 +0300 +++ b/emailservices/nmailagent/inc/nmmailagent.h Fri May 28 13:56:43 2010 +0300 @@ -23,6 +23,8 @@ class NmMailbox; class NmDataPluginFactory; class NmDataPluginInterface; +class HbIndicator; +class XQSystemToneService; class NmMailboxInfo { @@ -41,6 +43,7 @@ QList mUnreadMailIdList; int mOutboxMails; bool mActive; + QDateTime mLastSeenTime; NmMailboxInfo(); }; @@ -66,7 +69,7 @@ NmMessageEvent event, const NmId &folderId, const QList &messageIds, - const NmId& mailboxId); + const NmId &mailboxId); void handleSyncStateEvent( NmSyncState state, @@ -77,6 +80,8 @@ void delayedStart(); void enableAlertTone(); + + void indicatorActivated(const QString &type, const QVariantMap &data); private: @@ -84,10 +89,18 @@ bool updateUnreadCount(const NmId &mailboxId, NmMailboxInfo &mailboxInfo); - int getOutboxCount(const NmId& mailboxId); + int getOutboxCount(const NmId &mailboxId); + + NmMailboxInfo *getMailboxByType(const QString &type); - int getIndicatorIndex(); + int getFreeIndicatorIndex(); + + int getTotalUnreadCount() const; + bool updateUnreadIndicator(); + + bool updateUnreadIndicator(bool active); + bool updateIndicator(bool active, const NmMailboxInfo& mailboxInfo); @@ -108,14 +121,21 @@ bool getMessageUnreadInfo(const NmId &folderId, const NmId &messageId, const NmId &mailboxId, bool &unreadMessage); - void playAlertTone(); + bool playAlertTone(); + + void updateSendIndicator(); + + bool launchMailbox(quint64 mailboxId); private: // data + HbIndicator *mIndicator; + XQSystemToneService *mSystemTone; NmDataPluginFactory *mPluginFactory; QList mMailboxes; - bool mSendingState; bool mAlertToneAllowed; + int mLastOutboxCount; + bool mUnreadIndicatorActive; };