From e12ec78127ce3a52931d1b0fe62ff50cdf238960 Mon Sep 17 00:00:00 2001 From: prep linden Date: Thu, 21 Oct 2010 13:26:13 -0400 Subject: secondlife:///app/maptrackavatar/lluid secondlife:///app/sharewithavatar/lluid secondlife:///app/socialcallhandler/lluid <-work in progress --- indra/newview/llviewerinventory.cpp | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) (limited to 'indra/newview/llviewerinventory.cpp') diff --git a/indra/newview/llviewerinventory.cpp b/indra/newview/llviewerinventory.cpp index 75a5b14154..cf01792327 100644 --- a/indra/newview/llviewerinventory.cpp +++ b/indra/newview/llviewerinventory.cpp @@ -59,6 +59,7 @@ #include "llcommandhandler.h" #include "llviewermessage.h" #include "llsidepanelappearance.h" +#include "llavataractions.h" ///---------------------------------------------------------------------------- /// Helper class to store special inventory item names and their localized values. @@ -211,6 +212,37 @@ public: }; LLInventoryHandler gInventoryHandler; +//prep# share +class LLShareWithAvatarHandler : public LLCommandHandler +{ +public: + // requires trusted browser to trigger + LLShareWithAvatarHandler() : LLCommandHandler("sharewithavatar", UNTRUSTED_THROTTLE) + { + } + + bool handle(const LLSD& params, const LLSD& query_map, LLMediaCtrl* web) + { + //Make sure we have some parameters + if (params.size() == 0) + { + return false; + } + + //Get the ID + LLUUID id; + if (!id.set( params[0], FALSE )) + { + return false; + } + + //instigate share with this avatar + LLAvatarActions::share( id ); + return true; + } +}; +LLShareWithAvatarHandler gShareWithAvatar; + ///---------------------------------------------------------------------------- /// Class LLViewerInventoryItem ///---------------------------------------------------------------------------- -- cgit v1.2.3 From 03fd5c02f73467d50a10b62e982ce1dee961d315 Mon Sep 17 00:00:00 2001 From: prep linden Date: Thu, 21 Oct 2010 15:57:06 -0400 Subject: Added support for map tracking slapp, share slapp and a voice call slapp. slapp urls: secondlife:///app/maptrackavatar/lluid secondlife:///app/sharewithavatar/lluid secondlife:///app/voicecallavatar/lluid --- indra/newview/llviewerinventory.cpp | 30 ------------------------------ 1 file changed, 30 deletions(-) (limited to 'indra/newview/llviewerinventory.cpp') diff --git a/indra/newview/llviewerinventory.cpp b/indra/newview/llviewerinventory.cpp index cf01792327..1907aaea4e 100644 --- a/indra/newview/llviewerinventory.cpp +++ b/indra/newview/llviewerinventory.cpp @@ -212,36 +212,6 @@ public: }; LLInventoryHandler gInventoryHandler; -//prep# share -class LLShareWithAvatarHandler : public LLCommandHandler -{ -public: - // requires trusted browser to trigger - LLShareWithAvatarHandler() : LLCommandHandler("sharewithavatar", UNTRUSTED_THROTTLE) - { - } - - bool handle(const LLSD& params, const LLSD& query_map, LLMediaCtrl* web) - { - //Make sure we have some parameters - if (params.size() == 0) - { - return false; - } - - //Get the ID - LLUUID id; - if (!id.set( params[0], FALSE )) - { - return false; - } - - //instigate share with this avatar - LLAvatarActions::share( id ); - return true; - } -}; -LLShareWithAvatarHandler gShareWithAvatar; ///---------------------------------------------------------------------------- /// Class LLViewerInventoryItem -- cgit v1.2.3