diff options
author | Oz Linden <oz@lindenlab.com> | 2010-10-15 16:40:24 -0400 |
---|---|---|
committer | Oz Linden <oz@lindenlab.com> | 2010-10-15 16:40:24 -0400 |
commit | 18321756297bd9b04a4204abe4fbb0e3e8112186 (patch) | |
tree | 01e58c48ac8be93161d4a7002232ea7974637a39 /indra/newview/llfloatermap.cpp | |
parent | cc902e3d24c88bd49c591e81506875c5e3782b08 (diff) | |
parent | dd69516213fdf20cbc254214e651c4df26afbff7 (diff) |
pull fix for STORM-279
Diffstat (limited to 'indra/newview/llfloatermap.cpp')
-rw-r--r-- | indra/newview/llfloatermap.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/indra/newview/llfloatermap.cpp b/indra/newview/llfloatermap.cpp index c9d7eff02b..a1d291fea6 100644 --- a/indra/newview/llfloatermap.cpp +++ b/indra/newview/llfloatermap.cpp @@ -72,7 +72,6 @@ LLFloaterMap::LLFloaterMap(const LLSD& key) mTextBoxSouthWest(NULL), mMap(NULL) { - //Called from floater reg: LLUICtrlFactory::getInstance()->buildFloater(this, "floater_map.xml", FALSE); } LLFloaterMap::~LLFloaterMap() @@ -96,7 +95,7 @@ BOOL LLFloaterMap::postBuild() mTextBoxNorthWest = getChild<LLTextBox> ("floater_map_northwest"); LLUICtrl::CommitCallbackRegistry::ScopedRegistrar registrar; - + registrar.add("Minimap.Zoom", boost::bind(&LLFloaterMap::handleZoom, this, _2)); registrar.add("Minimap.Tracker", boost::bind(&LLFloaterMap::handleStopTracking, this, _2)); @@ -125,7 +124,9 @@ BOOL LLFloaterMap::postBuild() BOOL LLFloaterMap::handleDoubleClick( S32 x, S32 y, MASK mask ) { - LLFloaterReg::showInstance("world_map"); + // If floater is minimized, minimap should be shown on doubleclick (STORM-299) + std::string floater_to_show = this->isMinimized() ? "mini_map" : "world_map"; + LLFloaterReg::showInstance(floater_to_show); return TRUE; } @@ -258,7 +259,7 @@ void LLFloaterMap::reshape(S32 width, S32 height, BOOL called_from_parent) void LLFloaterMap::handleZoom(const LLSD& userdata) { std::string level = userdata.asString(); - + F32 scale = 0.0f; if (level == std::string("close")) scale = LLNetMap::MAP_SCALE_MAX; |