diff options
author | Oz Linden <oz@lindenlab.com> | 2013-11-18 19:05:34 -0500 |
---|---|---|
committer | Oz Linden <oz@lindenlab.com> | 2013-11-18 19:05:34 -0500 |
commit | 6bd777214c535b91048533c792cb2dd499ec6ebf (patch) | |
tree | 24cd4bb15bac292cfd71c39dcdd58e597fffb8e3 /indra/newview/llagent.h | |
parent | ebc9bcbf69f7a519677a6522979a6bf6cbb04bb8 (diff) |
add callbacks to LLAgent for Region and Parcel changes
Diffstat (limited to 'indra/newview/llagent.h')
-rwxr-xr-x | indra/newview/llagent.h | 28 |
1 files changed, 25 insertions, 3 deletions
diff --git a/indra/newview/llagent.h b/indra/newview/llagent.h index 7fac17d098..fafa166efd 100755 --- a/indra/newview/llagent.h +++ b/indra/newview/llagent.h @@ -231,15 +231,36 @@ private: LLVector3 mHomePosRegion; //-------------------------------------------------------------------- - // Region + // Parcel //-------------------------------------------------------------------- public: + void changeParcels(); // called by LLViewerParcelMgr when we cross a parcel boundary + + // Register a boost callback to be called when the agent changes parcels + typedef boost::function<void()> parcel_changed_callback_t; + boost::signals2::connection addParcelChangedCallback(parcel_changed_callback_t); + +private: + typedef boost::signals2::signal<void()> parcel_changed_signal_t; + parcel_changed_signal_t mParcelChangedSignal; + + //-------------------------------------------------------------------- + // Region + //-------------------------------------------------------------------- + public: void setRegion(LLViewerRegion *regionp); LLViewerRegion *getRegion() const; LLHost getRegionHost() const; BOOL inPrelude(); -private: + + // Register a boost callback to be called when the agent changes regions + typedef boost::function<void()> region_changed_callback_t; + boost::signals2::connection addRegionChangedCallback(region_changed_callback_t); + + private: LLViewerRegion *mRegionp; + typedef boost::signals2::signal<void()> region_changed_signal_t; + region_changed_signal_t mRegionChangedSignal; //-------------------------------------------------------------------- // History @@ -640,9 +661,10 @@ private: public: bool canEditParcel() const { return mCanEditParcel; } private: + static void setCanEditParcel(); bool mCanEditParcel; - static void parcelChangedCallback(); + /******************************************************************************** ** ** |