summaryrefslogtreecommitdiff
path: root/indra/llui/llpanel.cpp
diff options
context:
space:
mode:
authorbrad kittenbrink <brad@lindenlab.com>2009-08-04 15:34:34 -0700
committerbrad kittenbrink <brad@lindenlab.com>2009-08-04 15:34:34 -0700
commit33cc363a6813bf6c1268fa85747d1d403e00f8e5 (patch)
treed30696b245c4b5eb70575582d0dd9ddc4b20e5c7 /indra/llui/llpanel.cpp
parentdc62495da6e5c153c0df57fdbce6b0f40c0208f2 (diff)
parent89434ef6e64462041368ab26e049011fc84ae1e3 (diff)
Merged in latest viewer-2.0.0-3 up through svn r129410. LLFloaterTOS needs some post-merge cleanup.
Diffstat (limited to 'indra/llui/llpanel.cpp')
-rw-r--r--indra/llui/llpanel.cpp15
1 files changed, 13 insertions, 2 deletions
diff --git a/indra/llui/llpanel.cpp b/indra/llui/llpanel.cpp
index 9fb38bc316..1a948fdd00 100644
--- a/indra/llui/llpanel.cpp
+++ b/indra/llui/llpanel.cpp
@@ -74,7 +74,8 @@ LLPanel::Params::Params()
min_height("min_height", 100),
strings("string"),
filename("filename"),
- class_name("class")
+ class_name("class"),
+ visible_callback("visible_callback")
{
name = "panel";
addSynonym(background_visible, "bg_visible");
@@ -307,6 +308,12 @@ BOOL LLPanel::handleKeyHere( KEY key, MASK mask )
return handled;
}
+void LLPanel::handleVisibilityChange ( BOOL new_visibility )
+{
+ LLUICtrl::handleVisibilityChange ( new_visibility );
+ mVisibleSignal(this, LLSD(new_visibility) ); // Pass BOOL as LLSD
+}
+
BOOL LLPanel::checkRequirements()
{
if (!mRequirementsError.empty())
@@ -426,7 +433,11 @@ void LLPanel::initFromParams(const LLPanel::Params& p)
// control_name, tab_stop, focus_lost_callback, initial_value, rect, enabled, visible
LLUICtrl::initFromParams(p);
-
+
+ // visible callback
+ if (p.visible_callback.isProvided())
+ initCommitCallback(p.visible_callback, mVisibleSignal);
+
for (LLInitParam::ParamIterator<LocalizedString>::const_iterator it = p.strings().begin();
it != p.strings().end();
++it)