summaryrefslogtreecommitdiff
path: root/indra/llui/lldockablefloater.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llui/lldockablefloater.cpp')
-rw-r--r--indra/llui/lldockablefloater.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/indra/llui/lldockablefloater.cpp b/indra/llui/lldockablefloater.cpp
index 74438b184a..0492ab0f25 100644
--- a/indra/llui/lldockablefloater.cpp
+++ b/indra/llui/lldockablefloater.cpp
@@ -95,7 +95,7 @@ void LLDockableFloater::toggleInstance(const LLSD& sdname)
LLDockableFloater* instance =
dynamic_cast<LLDockableFloater*> (LLFloaterReg::findInstance(name));
// if floater closed or docked
- if (instance == NULL || instance != NULL && instance->isDocked())
+ if (instance == NULL || (instance && instance->isDocked()))
{
LLFloaterReg::toggleInstance(name, key);
// restore button toggle state
@@ -146,7 +146,7 @@ void LLDockableFloater::setVisible(BOOL visible)
if (visible)
{
- LLFloater::setFrontmost(TRUE);
+ LLFloater::setFrontmost(getAutoFocus());
}
LLFloater::setVisible(visible);
}
@@ -223,10 +223,10 @@ void LLDockableFloater::draw()
LLFloater::draw();
}
-void LLDockableFloater::setDockControl(LLDockControl* dockControl)
+void LLDockableFloater::setDockControl(LLDockControl* dockControl, bool docked /* = true */)
{
mDockControl.reset(dockControl);
- setDocked(mDockControl.get() != NULL && mDockControl.get()->isDockVisible());
+ setDocked(docked && mDockControl.get() != NULL && mDockControl.get()->isDockVisible());
}
const LLUIImagePtr& LLDockableFloater::getDockTongue()