summaryrefslogtreecommitdiff
path: root/indra/newview/llfloatermap.cpp
diff options
context:
space:
mode:
authorOz Linden <oz@lindenlab.com>2011-01-05 17:54:12 -0500
committerOz Linden <oz@lindenlab.com>2011-01-05 17:54:12 -0500
commit1034db639462d95e54e9bf9e4d63500b745bb0a2 (patch)
tree68b010fb3f9f2c4b67e59187d125090b1c69d72f /indra/newview/llfloatermap.cpp
parent0eb491417e8479516b07cc9237242b60d36d10f5 (diff)
parenteb0b8ab3ea19617a52881191bab21bfedcc5696d (diff)
merge changes for storm-806
Diffstat (limited to 'indra/newview/llfloatermap.cpp')
-rw-r--r--indra/newview/llfloatermap.cpp13
1 files changed, 10 insertions, 3 deletions
diff --git a/indra/newview/llfloatermap.cpp b/indra/newview/llfloatermap.cpp
index 351b9ac5da..1b94d8cbcd 100644
--- a/indra/newview/llfloatermap.cpp
+++ b/indra/newview/llfloatermap.cpp
@@ -83,7 +83,6 @@ LLFloaterMap::~LLFloaterMap()
BOOL LLFloaterMap::postBuild()
{
mMap = getChild<LLNetMap>("Net Map");
- mMap->setScale(gSavedSettings.getF32("MiniMapScale"));
mMap->setToolTipMsg(getString("ToolTipMsg"));
sendChildToBack(mMap);
@@ -288,7 +287,16 @@ void LLFloaterMap::handleZoom(const LLSD& userdata)
std::string level = userdata.asString();
F32 scale = 0.0f;
- if (level == std::string("close"))
+ if (level == std::string("default"))
+ {
+ LLControlVariable *pvar = gSavedSettings.getControl("MiniMapScale");
+ if(pvar)
+ {
+ pvar->resetToDefault();
+ scale = gSavedSettings.getF32("MiniMapScale");
+ }
+ }
+ else if (level == std::string("close"))
scale = LLNetMap::MAP_SCALE_MAX;
else if (level == std::string("medium"))
scale = LLNetMap::MAP_SCALE_MID;
@@ -296,7 +304,6 @@ void LLFloaterMap::handleZoom(const LLSD& userdata)
scale = LLNetMap::MAP_SCALE_MIN;
if (scale != 0.0f)
{
- gSavedSettings.setF32("MiniMapScale", scale );
mMap->setScale(scale);
}
}