summaryrefslogtreecommitdiff
path: root/indra/newview/llscriptfloater.cpp
diff options
context:
space:
mode:
authorLeyla Farazha <leyla@lindenlab.com>2010-07-27 14:13:07 -0700
committerLeyla Farazha <leyla@lindenlab.com>2010-07-27 14:13:07 -0700
commit0e06dc8964d5ae31fccb2da522d05d822530d3c7 (patch)
treed15dfd4ab9dfc4724efe62373cbca6a24c97006b /indra/newview/llscriptfloater.cpp
parent4c9760a073853ae81a78aa99119c059cdfaba664 (diff)
parentfe8a5a007ab82f3d6a763c5cb133e1299d238632 (diff)
Merge from dessie/viewer-release
Diffstat (limited to 'indra/newview/llscriptfloater.cpp')
-rw-r--r--indra/newview/llscriptfloater.cpp27
1 files changed, 4 insertions, 23 deletions
diff --git a/indra/newview/llscriptfloater.cpp b/indra/newview/llscriptfloater.cpp
index 75797dae81..b68fc3b002 100644
--- a/indra/newview/llscriptfloater.cpp
+++ b/indra/newview/llscriptfloater.cpp
@@ -176,15 +176,7 @@ void LLScriptFloater::onClose(bool app_quitting)
if(getNotificationId().notNull())
{
- // we shouldn't kill notification on exit since it may be used as persistent.
- if (app_quitting)
- {
- LLScriptFloaterManager::getInstance()->onRemoveNotification(getNotificationId());
- }
- else
- {
- LLScriptFloaterManager::getInstance()->removeNotification(getNotificationId());
- }
+ LLScriptFloaterManager::getInstance()->onRemoveNotification(getNotificationId());
}
}
@@ -360,7 +352,7 @@ void LLScriptFloaterManager::onAddNotification(const LLUUID& notification_id)
set_new_message |= !floater->hasFocus();
}
- removeNotification(it->first);
+ onRemoveNotification(it->first);
}
}
@@ -387,17 +379,6 @@ void LLScriptFloaterManager::onAddNotification(const LLUUID& notification_id)
toggleScriptFloater(notification_id, set_new_message);
}
-void LLScriptFloaterManager::removeNotification(const LLUUID& notification_id)
-{
- LLNotificationPtr notification = LLNotifications::instance().find(notification_id);
- if (notification != NULL && !notification->isCancelled())
- {
- LLNotificationsUtil::cancel(notification);
- }
-
- onRemoveNotification(notification_id);
-}
-
void LLScriptFloaterManager::onRemoveNotification(const LLUUID& notification_id)
{
if(notification_id.isNull())
@@ -411,8 +392,6 @@ void LLScriptFloaterManager::onRemoveNotification(const LLUUID& notification_id)
LLIMWellWindow::getInstance()->removeObjectRow(notification_id);
- mNotifications.erase(notification_id);
-
// close floater
LLScriptFloater* floater = LLFloaterReg::findTypedInstance<LLScriptFloater>("script_floater", notification_id);
if(floater)
@@ -421,6 +400,8 @@ void LLScriptFloaterManager::onRemoveNotification(const LLUUID& notification_id)
floater->setNotificationId(LLUUID::null);
floater->closeFloater();
}
+
+ mNotifications.erase(notification_id);
}
void LLScriptFloaterManager::toggleScriptFloater(const LLUUID& notification_id, bool set_new_message)