summaryrefslogtreecommitdiff
path: root/indra/newview/llfloaterfixedenvironment.cpp
diff options
context:
space:
mode:
authorRider Linden <rider@lindenlab.com>2018-09-18 18:17:54 +0000
committerRider Linden <rider@lindenlab.com>2018-09-18 18:17:54 +0000
commitc5283f63ab6571a3f48f30cc4eb2dbab3f0633ce (patch)
tree0719cb299fe3713c4aa7acfa834ae0bba49655ec /indra/newview/llfloaterfixedenvironment.cpp
parente53d35f4e8c9e15eda75f960b253481e1447b2b1 (diff)
parent89c48daf35ba1499100cdf81e07a91a75eea63c8 (diff)
Merged in andreykproductengine/maint-eep (pull request #94)
SL-9670 and SL-9678 Approved-by: Maxim Nikolenko <maximnproductengine@lindenlab.com>
Diffstat (limited to 'indra/newview/llfloaterfixedenvironment.cpp')
-rw-r--r--indra/newview/llfloaterfixedenvironment.cpp18
1 files changed, 18 insertions, 0 deletions
diff --git a/indra/newview/llfloaterfixedenvironment.cpp b/indra/newview/llfloaterfixedenvironment.cpp
index 9831a5fa84..d65a578a6d 100644
--- a/indra/newview/llfloaterfixedenvironment.cpp
+++ b/indra/newview/llfloaterfixedenvironment.cpp
@@ -292,12 +292,30 @@ void LLFloaterFixedEnvironment::checkAndConfirmSettingsLoss(LLFloaterFixedEnviro
void LLFloaterFixedEnvironment::onPickerCommitSetting(LLUUID asset_id)
{
+ mInventoryItem = NULL;
+ mInventoryId.setNull();
+ if (!mInventoryFloater.isDead())
+ {
+ LLFloaterSettingsPicker *picker = static_cast<LLFloaterSettingsPicker *>(mInventoryFloater.get());
+ if (picker)
+ {
+ mInventoryId = picker->findItemID(asset_id, false);
+ mInventoryItem = gInventory.getItem(mInventoryId);
+ }
+ }
+
LLSettingsVOBase::getSettingsAsset(asset_id,
[this](LLUUID asset_id, LLSettingsBase::ptr_t settings, S32 status, LLExtStat) { onAssetLoaded(asset_id, settings, status); });
}
void LLFloaterFixedEnvironment::onAssetLoaded(LLUUID asset_id, LLSettingsBase::ptr_t settings, S32 status)
{
+ if (mInventoryItem && mInventoryItem->getAssetUUID() != asset_id)
+ {
+ LL_WARNS("ENVIRONMENT") << "Discarding obsolete asset callback" << LL_ENDL;
+ return;
+ }
+
if (!settings || status)
{
LLSD args;