diff --git a/checkin_notes b/checkin_notes index 006a29d2e9..59d936914b 100644 --- a/checkin_notes +++ b/checkin_notes @@ -1406,3 +1406,11 @@ Rom 7 Mar 2011 clientgui/ DlgOptions.cpp, .h + +Rom 7 Mar 2011 + - MGR: Handle the 'always' option by only popping a new balloon if the + unread notice count differs from the last time we popped a + balloon. + + clientgui/ + BOINCTaskBar.cpp, .h diff --git a/clientgui/BOINCTaskBar.cpp b/clientgui/BOINCTaskBar.cpp index e9fe621ca5..b1d99aee8f 100644 --- a/clientgui/BOINCTaskBar.cpp +++ b/clientgui/BOINCTaskBar.cpp @@ -98,6 +98,7 @@ CTaskBarIcon::CTaskBarIcon(wxString title, wxIcon* icon, wxIcon* iconDisconnecte m_bMouseButtonPressed = false; m_dtLastNotificationAlertExecuted = wxDateTime((time_t)0); + m_iLastNotificationUnreadMessageCount = 0; #ifdef __WXMAC__ m_pNotificationRequest = NULL; #endif @@ -747,7 +748,9 @@ void CTaskBarIcon::UpdateNoticeStatus() { && (pFrame->GetReminderFrequency() != 0) ) { - if (pDoc->GetUnreadNoticeCount()) { + if (pDoc->GetUnreadNoticeCount() + && (pDoc->GetUnreadNoticeCount() != m_iLastNotificationUnreadMessageCount) + ) { #ifdef __WXMAC__ // Delay notification while user is inactive // NOTE: This API requires OS 10.4 or later @@ -759,6 +762,7 @@ void CTaskBarIcon::UpdateNoticeStatus() { #endif // Update cached info m_dtLastNotificationAlertExecuted = wxDateTime::Now(); + m_iLastNotificationUnreadMessageCount = pDoc->GetUnreadNoticeCount(); if (IsBalloonsSupported()) { // Display balloon diff --git a/clientgui/BOINCTaskBar.h b/clientgui/BOINCTaskBar.h index c8a7b3deb7..637d78b73b 100644 --- a/clientgui/BOINCTaskBar.h +++ b/clientgui/BOINCTaskBar.h @@ -112,6 +112,7 @@ private: bool m_bMouseButtonPressed; wxDateTime m_dtLastNotificationAlertExecuted; + int m_iLastNotificationUnreadMessageCount; void ResetTaskBar(); void DisplayContextMenu();