summaryrefslogtreecommitdiff
path: root/indra/newview/llviewermessage.h
diff options
context:
space:
mode:
authorVadim Savchuk <vsavchuk@productengine.com>2010-04-23 15:40:02 +0300
committerVadim Savchuk <vsavchuk@productengine.com>2010-04-23 15:40:02 +0300
commitd24a134df906d5a602bd939f48520bfdab08093b (patch)
treeca209e70a1adbfb7875e74d6ce36c56409f6e597 /indra/newview/llviewermessage.h
parentbb908fb73ee720898a22bda2119e3435992f0fef (diff)
parentb99c90daf38765161eafec418d52493761baf872 (diff)
Manual merge from default branch.
Semi-automatically resolved conflicts in: * BuildParams * indra/newview/CMakeLists.txt * indra/newview/llviewermessage.cpp --HG-- branch : product-engine
Diffstat (limited to 'indra/newview/llviewermessage.h')
-rw-r--r--indra/newview/llviewermessage.h25
1 files changed, 20 insertions, 5 deletions
diff --git a/indra/newview/llviewermessage.h b/indra/newview/llviewermessage.h
index 7c021dc05f..72ad3c8926 100644
--- a/indra/newview/llviewermessage.h
+++ b/indra/newview/llviewermessage.h
@@ -40,6 +40,7 @@
#include "lluuid.h"
#include "message.h"
#include "stdenums.h"
+#include "llnotifications.h"
//
// Forward declarations
@@ -210,11 +211,10 @@ bool highlight_offered_item(const LLUUID& item_id);
void set_dad_inventory_item(LLInventoryItem* inv_item, const LLUUID& into_folder_uuid);
-struct LLOfferInfo
+class LLOfferInfo : public LLNotificationResponderInterface
{
- LLOfferInfo()
- : mFromGroup(FALSE), mFromObject(FALSE),
- mIM(IM_NOTHING_SPECIAL), mType(LLAssetType::AT_NONE) {};
+public:
+ LLOfferInfo();
LLOfferInfo(const LLSD& sd);
LLOfferInfo(const LLOfferInfo& info);
@@ -232,12 +232,27 @@ struct LLOfferInfo
std::string mFromName;
std::string mDesc;
LLHost mHost;
+ bool mPersist;
+
+ // LLNotificationResponderInterface implementation
+ /*virtual*/ LLSD asLLSD();
+ /*virtual*/ void fromLLSD(const LLSD& params);
+ /*virtual*/ void handleRespond(const LLSD& notification, const LLSD& response);
- LLSD asLLSD();
void send_auto_receive_response(void);
+
+ // TODO - replace all references with handleRespond()
bool inventory_offer_callback(const LLSD& notification, const LLSD& response);
bool inventory_task_offer_callback(const LLSD& notification, const LLSD& response);
+private:
+
+ void initRespondFunctionMap();
+
+ typedef boost::function<bool (const LLSD&, const LLSD&)> respond_function_t;
+ typedef std::map<std::string, respond_function_t> respond_function_map_t;
+
+ respond_function_map_t mRespondFunctions;
};
void process_feature_disabled_message(LLMessageSystem* msg, void**);