diff options
author | Gilbert Gonzales <gilbert@lindenlab.com> | 2013-02-25 04:21:04 -0800 |
---|---|---|
committer | Gilbert Gonzales <gilbert@lindenlab.com> | 2013-02-25 04:21:04 -0800 |
commit | 33380b2fd9ab66d4cbe062f0a56cc655c18368f8 (patch) | |
tree | 92ef2d8cb909b307f9fbdb9591f73889adfc996f /indra/llui/llfloater.cpp | |
parent | c6929e42486dd6aa212dc523be4f3b65f431b016 (diff) | |
parent | ed1945b06d49d2b4ebff5b9fe933675fdcf1e71f (diff) |
merge
Diffstat (limited to 'indra/llui/llfloater.cpp')
-rw-r--r-- | indra/llui/llfloater.cpp | 27 |
1 files changed, 25 insertions, 2 deletions
diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp index 734e2cfda7..27dd7f5b32 100644 --- a/indra/llui/llfloater.cpp +++ b/indra/llui/llfloater.cpp @@ -813,6 +813,20 @@ void LLFloater::closeFloater(bool app_quitting) } /*virtual*/ +void LLFloater::closeHostedFloater() +{ + // When toggling *visibility*, close the host instead of the floater when hosted + if (getHost()) + { + getHost()->closeFloater(); + } + else + { + closeFloater(); + } +} + +/*virtual*/ void LLFloater::reshape(S32 width, S32 height, BOOL called_from_parent) { LLPanel::reshape(width, height, called_from_parent); @@ -1609,8 +1623,17 @@ void LLFloater::bringToFront( S32 x, S32 y ) // virtual void LLFloater::setVisibleAndFrontmost(BOOL take_focus) { - setVisible(TRUE); - setFrontmost(take_focus); + LLMultiFloater* hostp = getHost(); + if (hostp) + { + hostp->setVisible(TRUE); + hostp->setFrontmost(take_focus); + } + else + { + setVisible(TRUE); + setFrontmost(take_focus); + } } void LLFloater::setFrontmost(BOOL take_focus) |