summaryrefslogtreecommitdiff
path: root/indra/newview/llchiclet.cpp
diff options
context:
space:
mode:
authorMike Antipov <mantipov@productengine.com>2009-12-07 13:52:35 +0200
committerMike Antipov <mantipov@productengine.com>2009-12-07 13:52:35 +0200
commit4880959567436443b85bb45a963ed4ee5464dc45 (patch)
tree7b88da6c3e1b5aeda406d91903d7eddf11796597 /indra/newview/llchiclet.cpp
parent660d81834803354140029ca27dd718fa588f157d (diff)
Aditional changes for normal task EXT-3081 (Separate Message Well on Notifications Well and IM Well)
-- moved Notification well specific functionality from the "LLSysWellChiclet" into derived "LLNotificationChiclet" class --HG-- branch : product-engine
Diffstat (limited to 'indra/newview/llchiclet.cpp')
-rw-r--r--indra/newview/llchiclet.cpp23
1 files changed, 11 insertions, 12 deletions
diff --git a/indra/newview/llchiclet.cpp b/indra/newview/llchiclet.cpp
index 8d4e16df8e..8d627dc4c2 100644
--- a/indra/newview/llchiclet.cpp
+++ b/indra/newview/llchiclet.cpp
@@ -92,7 +92,6 @@ LLSysWellChiclet::LLSysWellChiclet(const Params& p)
: LLChiclet(p)
, mButton(NULL)
, mCounter(0)
-, mUreadSystemNotifications(0)
{
LLButton::Params button_params = p.button;
mButton = LLUICtrlFactory::create<LLButton>(button_params);
@@ -104,17 +103,6 @@ LLSysWellChiclet::~LLSysWellChiclet()
}
-void LLSysWellChiclet::connectCounterUpdatersToSignal(std::string notification_type)
-{
- LLNotificationsUI::LLNotificationManager* manager = LLNotificationsUI::LLNotificationManager::getInstance();
- LLNotificationsUI::LLEventHandler* n_handler = manager->getHandlerForNotification(notification_type);
- if(n_handler)
- {
- n_handler->setNewNotificationCallback(boost::bind(&LLNotificationChiclet::incUreadSystemNotifications, this));
- n_handler->setDelNotification(boost::bind(&LLNotificationChiclet::decUreadSystemNotifications, this));
- }
-}
-
void LLSysWellChiclet::setCounter(S32 counter)
{
std::string s_count;
@@ -160,6 +148,7 @@ void LLIMWellChiclet::messageCountChanged(const LLSD& session_data)
/************************************************************************/
LLNotificationChiclet::LLNotificationChiclet(const Params& p)
: LLSysWellChiclet(p)
+, mUreadSystemNotifications(0)
{
// connect counter handlers to the signals
connectCounterUpdatersToSignal("notify");
@@ -167,6 +156,16 @@ LLNotificationChiclet::LLNotificationChiclet(const Params& p)
connectCounterUpdatersToSignal("offer");
}
+void LLNotificationChiclet::connectCounterUpdatersToSignal(const std::string& notification_type)
+{
+ LLNotificationsUI::LLNotificationManager* manager = LLNotificationsUI::LLNotificationManager::getInstance();
+ LLNotificationsUI::LLEventHandler* n_handler = manager->getHandlerForNotification(notification_type);
+ if(n_handler)
+ {
+ n_handler->setNewNotificationCallback(boost::bind(&LLNotificationChiclet::incUreadSystemNotifications, this));
+ n_handler->setDelNotification(boost::bind(&LLNotificationChiclet::decUreadSystemNotifications, this));
+ }
+}
//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////