From 1c4d540afd488c5b64102fc14ea65433855f802a Mon Sep 17 00:00:00 2001 From: Leslie Linden Date: Wed, 5 Oct 2011 13:03:22 -0700 Subject: * Added function setOpenCallback to match existing setCloseCallback. --- indra/llui/llfloater.cpp | 9 +++++++-- indra/llui/llfloater.h | 1 + 2 files changed, 8 insertions(+), 2 deletions(-) (limited to 'indra') diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp index bc494e97f5..c28bcc2ec9 100644 --- a/indra/llui/llfloater.cpp +++ b/indra/llui/llfloater.cpp @@ -1029,7 +1029,7 @@ void LLFloater::setMinimized(BOOL minimize) if (minimize == mMinimized) return; - if(mMinimizeSignal) + if (mMinimizeSignal) { (*mMinimizeSignal)(this, LLSD(minimize)); } @@ -2857,7 +2857,7 @@ void LLFloater::initFromParams(const LLFloater::Params& p) // open callback if (p.open_callback.isProvided()) { - mOpenSignal.connect(initCommitCallback(p.open_callback)); + setOpenCallback(initCommitCallback(p.open_callback)); } // close callback if (p.close_callback.isProvided()) @@ -2872,6 +2872,11 @@ boost::signals2::connection LLFloater::setMinimizeCallback( const commit_signal_ return mMinimizeSignal->connect(cb); } +boost::signals2::connection LLFloater::setOpenCallback( const commit_signal_t::slot_type& cb ) +{ + return mOpenSignal.connect(cb); +} + boost::signals2::connection LLFloater::setCloseCallback( const commit_signal_t::slot_type& cb ) { return mCloseSignal.connect(cb); diff --git a/indra/llui/llfloater.h b/indra/llui/llfloater.h index fba59e82e1..5aff542049 100644 --- a/indra/llui/llfloater.h +++ b/indra/llui/llfloater.h @@ -144,6 +144,7 @@ public: bool buildFromFile(const std::string &filename, LLXMLNodePtr output_node = NULL); boost::signals2::connection setMinimizeCallback( const commit_signal_t::slot_type& cb ); + boost::signals2::connection setOpenCallback( const commit_signal_t::slot_type& cb ); boost::signals2::connection setCloseCallback( const commit_signal_t::slot_type& cb ); void initFromParams(const LLFloater::Params& p); -- cgit v1.2.3