summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorCho <cho@lindenlab.com>2014-07-18 01:45:48 +0100
committerCho <cho@lindenlab.com>2014-07-18 01:45:48 +0100
commit3b2f456416d29534cb41fc9d4ad3bf195dcfc847 (patch)
tree0034fd78f60fb3c1509e75fd7fdcd2f7d42e0355 /indra
parent487fce4afaed69268db4fb996e420ba8984101d3 (diff)
Added mLocationSLURL to fix ACME-1560
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/llfloaterexperienceprofile.cpp23
-rw-r--r--indra/newview/llfloaterexperienceprofile.h1
2 files changed, 13 insertions, 11 deletions
diff --git a/indra/newview/llfloaterexperienceprofile.cpp b/indra/newview/llfloaterexperienceprofile.cpp
index 764d9088a1..4ee31f5df1 100644
--- a/indra/newview/llfloaterexperienceprofile.cpp
+++ b/indra/newview/llfloaterexperienceprofile.cpp
@@ -477,18 +477,18 @@ void LLFloaterExperienceProfile::refreshExperience( const LLSD& experience )
LLTextEditor* edit_child = getChild<LLTextEditor>(EDIT TF_DESC);
edit_child->setText(value);
- value = experience[LLExperienceCache::SLURL].asString();
+ mLocationSLURL = experience[LLExperienceCache::SLURL].asString();
child = getChild<LLTextBox>(TF_SLURL);
- bool has_value = value.length()>0;
- locationPanel->setVisible(has_value);
- value = LLSLURL(value).getSLURLString();
- child->setText(value);
+ bool has_slurl = mLocationSLURL.length()>0;
+ locationPanel->setVisible(has_slurl);
+ mLocationSLURL = LLSLURL(mLocationSLURL).getSLURLString();
+ child->setText(mLocationSLURL);
child = getChild<LLTextBox>(EDIT TF_SLURL);
- if(has_value)
+ if(has_slurl)
{
- child->setText(value);
+ child->setText(mLocationSLURL);
}
else
{
@@ -829,7 +829,8 @@ void LLFloaterExperienceProfile::onClickLocation()
if(region)
{
LLTextBox* child = getChild<LLTextBox>(EDIT TF_SLURL);
- child->setText(LLSLURL(region->getName(), gAgent.getPositionGlobal()).getSLURLString());
+ mLocationSLURL = LLSLURL(region->getName(), gAgent.getPositionGlobal()).getSLURLString();
+ child->setText(mLocationSLURL);
onFieldChanged();
}
}
@@ -837,6 +838,7 @@ void LLFloaterExperienceProfile::onClickLocation()
void LLFloaterExperienceProfile::onClickClear()
{
LLTextBox* child = getChild<LLTextBox>(EDIT TF_SLURL);
+ mLocationSLURL = "";
child->setText(getString("empty_slurl"));
onFieldChanged();
}
@@ -916,14 +918,13 @@ void LLFloaterExperienceProfile::updatePackage()
{
mPackage[LLExperienceCache::NAME] = getChild<LLLineEditor>(EDIT TF_NAME)->getText();
mPackage[LLExperienceCache::DESCRIPTION] = getChild<LLTextEditor>(EDIT TF_DESC)->getText();
- std::string slurl = getChild<LLTextBox>(EDIT TF_SLURL)->getText();
- if(slurl == getString("empty_slurl"))
+ if(mLocationSLURL.empty())
{
mPackage[LLExperienceCache::SLURL] = LLStringUtil::null;
}
else
{
- mPackage[LLExperienceCache::SLURL] = slurl;
+ mPackage[LLExperienceCache::SLURL] = mLocationSLURL;
}
mPackage[LLExperienceCache::MATURITY] = getChild<LLComboBox>(EDIT TF_MATURITY)->getSelectedValue().asInteger();
diff --git a/indra/newview/llfloaterexperienceprofile.h b/indra/newview/llfloaterexperienceprofile.h
index b66df49a8a..78d54eb447 100644
--- a/indra/newview/llfloaterexperienceprofile.h
+++ b/indra/newview/llfloaterexperienceprofile.h
@@ -95,6 +95,7 @@ protected:
LLUUID mExperienceId;
LLSD mExperienceDetails;
LLSD mPackage;
+ std::string mLocationSLURL;
int mSaveCompleteAction;
bool mDirty;
bool mForceClose;