summaryrefslogtreecommitdiff
path: root/indra/llui/llfloaterreg.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llui/llfloaterreg.cpp')
-rw-r--r--indra/llui/llfloaterreg.cpp23
1 files changed, 23 insertions, 0 deletions
diff --git a/indra/llui/llfloaterreg.cpp b/indra/llui/llfloaterreg.cpp
index 27e96856b3..d0ae9413a3 100644
--- a/indra/llui/llfloaterreg.cpp
+++ b/indra/llui/llfloaterreg.cpp
@@ -478,6 +478,7 @@ void LLFloaterReg::toggleToolbarFloaterInstance(const LLSD& sdname)
if (LLFloater::isMinimized(instance))
{
instance->setMinimized(FALSE);
+ instance->setFocus(TRUE);
}
else if (!LLFloater::isShown(instance))
{
@@ -494,6 +495,28 @@ void LLFloaterReg::toggleToolbarFloaterInstance(const LLSD& sdname)
}
//static
+bool LLFloaterReg::floaterInstanceOpen(const LLSD& sdname)
+{
+ LLSD key;
+ std::string name = sdname.asString();
+ parse_name_key(name, key);
+
+ bool visible_or_minimized = instanceVisible(name, key);
+
+ if (!visible_or_minimized)
+ {
+ LLFloater* instance = findInstance(name, key);
+
+ if (instance != NULL)
+ {
+ visible_or_minimized = LLFloater::isMinimized(instance);
+ }
+ }
+
+ return visible_or_minimized;
+}
+
+//static
bool LLFloaterReg::floaterInstanceVisible(const LLSD& sdname)
{
LLSD key;