summaryrefslogtreecommitdiff
path: root/indra/newview/llpathfindingobject.h
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llpathfindingobject.h')
-rw-r--r--indra/newview/llpathfindingobject.h41
1 files changed, 30 insertions, 11 deletions
diff --git a/indra/newview/llpathfindingobject.h b/indra/newview/llpathfindingobject.h
index 880a3a6864..b8d3ca2364 100644
--- a/indra/newview/llpathfindingobject.h
+++ b/indra/newview/llpathfindingobject.h
@@ -27,13 +27,16 @@
#ifndef LL_LLPATHFINDINGOBJECT_H
#define LL_LLPATHFINDINGOBJECT_H
-#include "llavatarname.h"
-#include "lluuid.h"
-#include "v3math.h"
-
#include <string>
#include <boost/shared_ptr.hpp>
+#include <boost/function.hpp>
+#include <boost/signals2.hpp>
+
+#include "llavatarname.h"
+#include "llavatarnamecache.h"
+#include "lluuid.h"
+#include "v3math.h"
class LLPathfindingObject;
class LLSD;
@@ -53,21 +56,37 @@ public:
inline const LLUUID& getUUID() const {return mUUID;};
inline const std::string& getName() const {return mName;};
inline const std::string& getDescription() const {return mDescription;};
- inline BOOL hasOwnerName() const {return mOwnerUUID.notNull();};
+ inline BOOL hasOwner() const {return mOwnerUUID.notNull();};
+ inline bool hasOwnerName() const {return mHasOwnerName;};
std::string getOwnerName() const;
+ inline BOOL isGroupOwned() const {return mIsGroupOwned;};
inline const LLVector3& getLocation() const {return mLocation;};
+ typedef boost::function<void (const LLPathfindingObject *)> name_callback_t;
+ typedef boost::signals2::signal<void (const LLPathfindingObject *)> name_signal_t;
+ typedef boost::signals2::connection name_connection_t;
+
+ name_connection_t registerOwnerNameListener(name_callback_t pOwnerNameCallback);
+
protected:
private:
void parseObjectData(const LLSD &pObjectData);
- LLUUID mUUID;
- std::string mName;
- std::string mDescription;
- LLUUID mOwnerUUID;
- LLAvatarName mOwnerName;
- LLVector3 mLocation;
+ void fetchOwnerName();
+ void handleAvatarNameFetch(const LLUUID &pOwnerUUID, const LLAvatarName &pAvatarName);
+ void disconnectAvatarNameCacheConnection();
+
+ LLUUID mUUID;
+ std::string mName;
+ std::string mDescription;
+ LLUUID mOwnerUUID;
+ bool mHasOwnerName;
+ LLAvatarName mOwnerName;
+ LLAvatarNameCache::callback_connection_t mAvatarNameCacheConnection;
+ BOOL mIsGroupOwned;
+ LLVector3 mLocation;
+ name_signal_t mOwnerNameSignal;
};
#endif // LL_LLPATHFINDINGOBJECT_H