From 38ba526cc57799211c4d926a6b4009cef32d21cd Mon Sep 17 00:00:00 2001 From: Richard Linden Date: Wed, 13 Jul 2011 17:59:53 -0700 Subject: EXP-1009 WIP Teleport links from Search floater and destination guide in viewer fail with intrusted browser error in viewer --- indra/llui/llfloaterreg.cpp | 7 +++++-- indra/llui/llsdparam.h | 1 + 2 files changed, 6 insertions(+), 2 deletions(-) (limited to 'indra/llui') diff --git a/indra/llui/llfloaterreg.cpp b/indra/llui/llfloaterreg.cpp index 4677d535db..f5e6444287 100644 --- a/indra/llui/llfloaterreg.cpp +++ b/indra/llui/llfloaterreg.cpp @@ -129,7 +129,10 @@ LLFloater* LLFloaterReg::getInstance(const std::string& name, const LLSD& key) } // Note: key should eventually be a non optional LLFloater arg; for now, set mKey to be safe - res->mKey = key; + if (res->mKey.isUndefined()) + { + res->mKey = key; + } res->setInstanceName(name); res->applySavedVariables(); // Can't apply rect and dock state until setting instance name if (res->mAutoTile && !res->getHost() && index > 0) @@ -221,7 +224,7 @@ LLFloater* LLFloaterReg::showInstance(const std::string& name, const LLSD& key, LLFloater* instance = getInstance(name, key); if (instance) { - instance->openFloater(key); + instance->openFloater(instance->mKey); if (focus) instance->setFocus(TRUE); } diff --git a/indra/llui/llsdparam.h b/indra/llui/llsdparam.h index 827b8c8584..f776c781b3 100644 --- a/indra/llui/llsdparam.h +++ b/indra/llui/llsdparam.h @@ -103,6 +103,7 @@ class LLSDParamAdapter : public T } LLSDParamAdapter(const T& val) + : T(val) { T::operator=(val); } -- cgit v1.2.3