diff options
-rw-r--r-- | indra/llui/llnotifications.cpp | 17 | ||||
-rw-r--r-- | indra/newview/llviewermessage.cpp | 1 |
2 files changed, 14 insertions, 4 deletions
diff --git a/indra/llui/llnotifications.cpp b/indra/llui/llnotifications.cpp index 2da8f1eb1b..7cc6e8e8f6 100644 --- a/indra/llui/llnotifications.cpp +++ b/indra/llui/llnotifications.cpp @@ -1425,17 +1425,26 @@ void LLNotifications::cancel(LLNotificationPtr pNotif) void LLNotifications::cancelByName(const std::string& name) { - for (LLNotificationSet::iterator it=mItems.begin(), end_it = mItems.end(), next_it = it; + std::vector<LLNotificationPtr> notifs_to_cancel; + for (LLNotificationSet::iterator it=mItems.begin(), end_it = mItems.end(); it != end_it; - it = next_it, ++next_it) + ++it) { LLNotificationPtr pNotif = *it; if (pNotif->getName() == name) { - pNotif->cancel(); - updateItem(LLSD().with("sigtype", "delete").with("id", pNotif->id()), pNotif); + notifs_to_cancel.push_back(pNotif); } } + + for (std::vector<LLNotificationPtr>::iterator it = notifs_to_cancel.begin(), end_it = notifs_to_cancel.end(); + it != end_it; + ++it) + { + LLNotificationPtr pNotif = *it; + pNotif->cancel(); + updateItem(LLSD().with("sigtype", "delete").with("id", pNotif->id()), pNotif); + } } void LLNotifications::update(const LLNotificationPtr pNotif) diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp index 9bb734a3d3..067c0f3a80 100644 --- a/indra/newview/llviewermessage.cpp +++ b/indra/newview/llviewermessage.cpp @@ -1080,6 +1080,7 @@ bool check_offer_throttle(const std::string& from_name, bool check_only) void open_inventory_offer(const uuid_vec_t& objects, const std::string& from_name) { + LLFirstUse::inventoryOffer(); for (uuid_vec_t::const_iterator obj_iter = objects.begin(); obj_iter != objects.end(); ++obj_iter) |