diff options
author | Steven Bennetts <steve@lindenlab.com> | 2009-06-21 08:04:56 +0000 |
---|---|---|
committer | Steven Bennetts <steve@lindenlab.com> | 2009-06-21 08:04:56 +0000 |
commit | 9ec432034dc3c45d7ce763eb02dae4cc7f6b8da8 (patch) | |
tree | 4a505c1e0919af52800b3ffb3eaf135e7d6f9ce6 /indra/newview/llfloatergroups.h | |
parent | 351ebe9fcb76f3b99c2957004bb8493a904869ee (diff) |
merge -r 122421-124917 viewer-2.0.0-2 -> viewer-2.0.0-3
ignore-dead-branch
Diffstat (limited to 'indra/newview/llfloatergroups.h')
-rw-r--r-- | indra/newview/llfloatergroups.h | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/indra/newview/llfloatergroups.h b/indra/newview/llfloatergroups.h index 3eb3e5af52..b49d38ccd0 100644 --- a/indra/newview/llfloatergroups.h +++ b/indra/newview/llfloatergroups.h @@ -47,6 +47,8 @@ #include "lluuid.h" #include "llfloater.h" #include <map> +#include <boost/function.hpp> +#include <boost/signal.hpp> class LLUICtrl; class LLTextBox; @@ -59,8 +61,10 @@ class LLFloaterGroupPicker : public LLFloater, public LLUIFactory<LLFloaterGroup friend class LLUIFactory<LLFloaterGroupPicker>; public: ~LLFloaterGroupPicker(); - void setSelectCallback( void (*callback)(LLUUID, void*), - void* userdata); + + // Note: Don't return connection; use boost::bind + boost::signal::trackable to disconnect slots + typedef boost::signal<void (LLUUID id)> signal_t; + void setSelectGroupCallback(const signal_t::slot_type& cb) { mGroupSelectSignal.connect(cb); } void setPowersMask(U64 powers_mask); BOOL postBuild(); @@ -77,8 +81,7 @@ protected: protected: LLUUID mID; U64 mPowersMask; - void (*mSelectCallback)(LLUUID id, void* userdata); - void* mCallbackUserdata; + signal_t mGroupSelectSignal; typedef std::map<const LLUUID, LLFloaterGroupPicker*> instance_map_t; static instance_map_t sInstances; |