LLAvatarActions all hooked up!
Rlva style~ So update to RLVa stuff! Adds support for @startim and @startimto Enables hasOpenIM and hasOpenProfile, Yay functionality! RLV_BHVR_STARTIM and RLV_BHVR_STARTIMTO added While I was working, I was updating LLAgentHandler, after long enough it was identical enough to the one in llpanelprofile, so we're using that now. Cleans up llfloateravatarinfo to the point of being a floater and instancetracker wrapper for a panelavatar (profile panel) Bypasses looking up expired names that we know via get, this should avoid chats (and profiles, but that bug never got out) never opening for people we already know the name of on a bad connection; of course, this will only cause a faster reaction on the UI's part, messages may never get sent still (and profiles may never load) if the connection is truly terrible. Cleans up llfloaterfriends and some parts of llfloateravatarlist (avatarlist could be cleaned up more from this perhaps in the future) May slightly look better with copy detection and without space changes.. llgivemoney.cpp changes fix up some dummy view warnings I noticed while testing these changes llpreview.cpp changes avoid segfault caused by llfloateravatarinfo not being a preview anymore but being inside a multipreview nonetheless. Translators, don't worry, I covered this one with updates from v3 (Except German team)
This commit is contained in:
@@ -118,6 +118,7 @@ set(viewer_SOURCE_FILES
|
||||
llassetuploadresponders.cpp
|
||||
llattachmentsmgr.cpp
|
||||
llaudiosourcevo.cpp
|
||||
llavataractions.cpp
|
||||
llavatarpropertiesprocessor.cpp
|
||||
llbox.cpp
|
||||
llcallbacklist.cpp
|
||||
@@ -615,6 +616,7 @@ set(viewer_HEADER_FILES
|
||||
llassetuploadresponders.h
|
||||
llattachmentsmgr.h
|
||||
llaudiosourcevo.h
|
||||
llavataractions.h
|
||||
llavatarpropertiesprocessor.h
|
||||
llbox.h
|
||||
llcallbacklist.h
|
||||
|
||||
734
indra/newview/llavataractions.cpp
Normal file
734
indra/newview/llavataractions.cpp
Normal file
@@ -0,0 +1,734 @@
|
||||
/**
|
||||
* @file llavataractions.cpp
|
||||
* @brief Friend-related actions (add, remove, offer teleport, etc)
|
||||
*
|
||||
* $LicenseInfo:firstyear=2009&license=viewerlgpl$
|
||||
* Second Life Viewer Source Code
|
||||
* Copyright (C) 2010, Linden Research, Inc.
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation;
|
||||
* version 2.1 of the License only.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*
|
||||
* Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
|
||||
* $/LicenseInfo$
|
||||
*/
|
||||
|
||||
|
||||
#include "llviewerprecompiledheaders.h"
|
||||
|
||||
#include "llavataractions.h"
|
||||
|
||||
#include "llavatarnamecache.h" // IDEVO
|
||||
#include "llnotificationsutil.h" // for LLNotificationsUtil
|
||||
#include "roles_constants.h" // for GP_MEMBER_INVITE
|
||||
|
||||
#include "llagent.h"
|
||||
#include "llcallingcard.h" // LLAvatarTracker
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "llfloatergroupinvite.h"
|
||||
#include "llfloatergroups.h"
|
||||
#include "llfloaterworldmap.h"
|
||||
#include "llgivemoney.h"
|
||||
#include "llimview.h" // for gIMMgr
|
||||
#include "llinventoryobserver.h"
|
||||
#include "llmutelist.h"
|
||||
#include "lltrans.h"
|
||||
#include "llvoiceclient.h"
|
||||
#include "llweb.h"
|
||||
// [RLVa:KB] - Checked: 2011-04-11 (RLVa-1.3.0h) | Added: RLVa-1.3.0h
|
||||
#include "rlvhandler.h"
|
||||
// [/RLVa:KB]
|
||||
|
||||
extern const S32 TRANS_GIFT;
|
||||
void give_money(const LLUUID& uuid, LLViewerRegion* region, S32 amount, BOOL is_group = FALSE, S32 trx_type = TRANS_GIFT, const std::string& desc = LLStringUtil::null);
|
||||
void handle_lure(const uuid_vec_t& ids);
|
||||
void send_improved_im(const LLUUID& to_id, const std::string& name, const std::string& message, U8 offline, EInstantMessage dialog, const LLUUID& id, U32 timestamp = NO_TIMESTAMP, const U8* binary_bucket = (U8*)EMPTY_BINARY_BUCKET, S32 binary_bucket_size = EMPTY_BINARY_BUCKET_SIZE);
|
||||
|
||||
// static
|
||||
void LLAvatarActions::requestFriendshipDialog(const LLUUID& id, const std::string& name)
|
||||
{
|
||||
if(id == gAgentID)
|
||||
{
|
||||
LLNotificationsUtil::add("AddSelfFriend");
|
||||
return;
|
||||
}
|
||||
|
||||
LLSD args;
|
||||
args["NAME"] = name;
|
||||
LLSD payload;
|
||||
payload["id"] = id;
|
||||
payload["name"] = name;
|
||||
|
||||
LLNotificationsUtil::add("AddFriendWithMessage", args, payload, &callbackAddFriendWithMessage);
|
||||
}
|
||||
|
||||
void on_avatar_name_friendship(const LLUUID& id, const LLAvatarName av_name)
|
||||
{
|
||||
LLAvatarActions::requestFriendshipDialog(id, av_name.getCompleteName());
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::requestFriendshipDialog(const LLUUID& id)
|
||||
{
|
||||
if(id.isNull())
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
LLAvatarNameCache::get(id, boost::bind(&on_avatar_name_friendship, _1, _2));
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::removeFriendDialog(const LLUUID& id)
|
||||
{
|
||||
if (id.isNull())
|
||||
return;
|
||||
|
||||
uuid_vec_t ids;
|
||||
ids.push_back(id);
|
||||
removeFriendsDialog(ids);
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::removeFriendsDialog(const uuid_vec_t& ids)
|
||||
{
|
||||
if(ids.size() == 0)
|
||||
return;
|
||||
|
||||
LLSD args;
|
||||
std::string msgType;
|
||||
if(ids.size() == 1)
|
||||
{
|
||||
LLUUID agent_id = ids[0];
|
||||
std::string av_name;
|
||||
if(LLAvatarNameCache::getPNSName(agent_id, av_name))
|
||||
{
|
||||
args["NAME"] = av_name;
|
||||
}
|
||||
|
||||
msgType = "RemoveFromFriends";
|
||||
}
|
||||
else
|
||||
{
|
||||
msgType = "RemoveMultipleFromFriends";
|
||||
}
|
||||
|
||||
LLSD payload;
|
||||
for (uuid_vec_t::const_iterator it = ids.begin(); it != ids.end(); ++it)
|
||||
{
|
||||
payload["ids"].append(*it);
|
||||
}
|
||||
|
||||
LLNotificationsUtil::add(msgType,
|
||||
args,
|
||||
payload,
|
||||
&handleRemove);
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::offerTeleport(const LLUUID& invitee)
|
||||
{
|
||||
if (invitee.isNull())
|
||||
return;
|
||||
|
||||
LLDynamicArray<LLUUID> ids;
|
||||
ids.push_back(invitee);
|
||||
offerTeleport(ids);
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::offerTeleport(const uuid_vec_t& ids)
|
||||
{
|
||||
if (ids.size() == 0)
|
||||
return;
|
||||
|
||||
handle_lure(ids);
|
||||
}
|
||||
|
||||
static void on_avatar_name_cache_start_im(const LLUUID& agent_id, const LLAvatarName& av_name)
|
||||
{
|
||||
static LLCachedControl<bool> tear_off("OtherChatsTornOff");
|
||||
if (!tear_off) gIMMgr->setFloaterOpen(true);
|
||||
gIMMgr->addSession(LLCacheName::cleanFullName(av_name.getLegacyName()), IM_NOTHING_SPECIAL, agent_id);
|
||||
make_ui_sound("UISndStartIM");
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::startIM(const LLUUID& id)
|
||||
{
|
||||
if (id.isNull() || gAgentID == id)
|
||||
return;
|
||||
|
||||
// [RLVa:KB] - Checked: 2011-04-11 (RLVa-1.3.0h) | Added: RLVa-1.3.0h
|
||||
if ( (rlv_handler_t::isEnabled()) && (!gRlvHandler.canStartIM(id)) )
|
||||
{
|
||||
LLUUID idSession = gIMMgr->computeSessionID(IM_NOTHING_SPECIAL, id);
|
||||
if ( (idSession.notNull()) && (!gIMMgr->hasSession(idSession)) )
|
||||
{
|
||||
make_ui_sound("UISndInvalidOp");
|
||||
RlvUtil::notifyBlocked(RLV_STRING_BLOCKED_STARTIM, LLSD().with("RECIPIENT", id/*LLSLURL("agent", id, "completename").getSLURLString()*/));
|
||||
return;
|
||||
}
|
||||
}
|
||||
// [/RLVa:KB]
|
||||
|
||||
LLAvatarName av_name;
|
||||
if (LLAvatarNameCache::get(id, &av_name)) // Bypass expiration, open NOW!
|
||||
on_avatar_name_cache_start_im(id, av_name);
|
||||
else
|
||||
LLAvatarNameCache::get(id, boost::bind(&on_avatar_name_cache_start_im, _1, _2));
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::endIM(const LLUUID& id)
|
||||
{
|
||||
if (id.isNull())
|
||||
return;
|
||||
|
||||
LLUUID session_id = gIMMgr->computeSessionID(IM_NOTHING_SPECIAL, id);
|
||||
if (session_id.notNull())
|
||||
{
|
||||
gIMMgr->removeSession(session_id);
|
||||
}
|
||||
}
|
||||
|
||||
/* Singu TODO: Voice refactor
|
||||
static void on_avatar_name_cache_start_call(const LLUUID& agent_id,
|
||||
const LLAvatarName& av_name)
|
||||
{
|
||||
LLUUID session_id = gIMMgr->addSession(LLCacheName::cleanFullName(av_name.getLegacyName()), IM_NOTHING_SPECIAL, agent_id, true);
|
||||
if (session_id.notNull())
|
||||
{
|
||||
gIMMgr->startCall(session_id);
|
||||
}
|
||||
make_ui_sound("UISndStartIM");
|
||||
}
|
||||
|
||||
|
||||
// static
|
||||
void LLAvatarActions::startCall(const LLUUID& id)
|
||||
{
|
||||
if (id.isNull())
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
// [RLVa:KB] - Checked: 2011-04-11 (RLVa-1.3.0h) | Added: RLVa-1.3.0h
|
||||
if ( (rlv_handler_t::isEnabled()) && (!gRlvHandler.canStartIM(id)) )
|
||||
{
|
||||
LLUUID idSession = gIMMgr->computeSessionID(IM_NOTHING_SPECIAL, id);
|
||||
if ( (idSession.notNull()) && (!gIMMgr->hasSession(idSession)) )
|
||||
{
|
||||
make_ui_sound("UISndInvalidOp");
|
||||
RlvUtil::notifyBlocked(RLV_STRING_BLOCKED_STARTIM, LLSD().with("RECIPIENT", id));//LLSLURL("agent", id, "completename").getSLURLString()));
|
||||
return;
|
||||
}
|
||||
}
|
||||
// [/RLVa:KB]
|
||||
|
||||
LLAvatarNameCache::get(id,
|
||||
boost::bind(&on_avatar_name_cache_start_call, _1, _2));
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::startAdhocCall(const uuid_vec_t& ids)
|
||||
{
|
||||
if (ids.size() == 0)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
// convert vector into LLDynamicArray for addSession
|
||||
LLDynamicArray<LLUUID> id_array;
|
||||
for (uuid_vec_t::const_iterator it = ids.begin(); it != ids.end(); ++it)
|
||||
{
|
||||
// [RLVa:KB] - Checked: 2011-04-11 (RLVa-1.3.0h) | Added: RLVa-1.3.0h
|
||||
const LLUUID& idAgent = *it;
|
||||
if ( (rlv_handler_t::isEnabled()) && (!gRlvHandler.canStartIM(idAgent)) )
|
||||
{
|
||||
make_ui_sound("UISndInvalidOp");
|
||||
RlvUtil::notifyBlocked(RLV_STRING_BLOCKED_STARTCONF, LLSD().with("RECIPIENT", idAgent));//LLSLURL("agent", idAgent, "completename").getSLURLString()));
|
||||
return;
|
||||
}
|
||||
id_array.push_back(idAgent);
|
||||
// [/RLVa:KB]
|
||||
// id_array.push_back(*it);
|
||||
}
|
||||
|
||||
// create the new ad hoc voice session
|
||||
const std::string title = LLTrans::getString("conference-title");
|
||||
LLUUID session_id = gIMMgr->addSession(title, IM_SESSION_CONFERENCE_START,
|
||||
ids[0], id_array, true);
|
||||
if (session_id.isNull())
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
gIMMgr->autoStartCallOnStartup(session_id);
|
||||
|
||||
make_ui_sound("UISndStartIM");
|
||||
}
|
||||
*/
|
||||
|
||||
/* AD *TODO: Is this function needed any more?
|
||||
I fixed it a bit(added check for canCall), but it appears that it is not used
|
||||
anywhere. Maybe it should be removed?
|
||||
// static
|
||||
bool LLAvatarActions::isCalling(const LLUUID &id)
|
||||
{
|
||||
if (id.isNull() || !canCall())
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
LLUUID session_id = gIMMgr->computeSessionID(IM_NOTHING_SPECIAL, id);
|
||||
return (LLIMModel::getInstance()->findIMSession(session_id) != NULL);
|
||||
}*/
|
||||
|
||||
//static
|
||||
bool LLAvatarActions::canCall()
|
||||
{
|
||||
return LLVoiceClient::getInstance()->voiceEnabled() /*&& LLVoiceClient::getInstance()->isVoiceWorking()*/;
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::startConference(const uuid_vec_t& ids)
|
||||
{
|
||||
for (uuid_vec_t::const_iterator it = ids.begin(); it != ids.end(); ++it)
|
||||
{
|
||||
// [RLVa:KB] - Checked: 2011-04-11 (RLVa-1.3.0h) | Added: RLVa-1.3.0h
|
||||
const LLUUID& idAgent = *it;
|
||||
if ( (rlv_handler_t::isEnabled()) && (!gRlvHandler.canStartIM(idAgent)) )
|
||||
{
|
||||
make_ui_sound("UISndInvalidOp");
|
||||
RlvUtil::notifyBlocked(RLV_STRING_BLOCKED_STARTCONF, LLSD().with("RECIPIENT", idAgent/*LLSLURL("agent", idAgent, "completename").getSLURLString()*/));
|
||||
return;
|
||||
}
|
||||
// [/RLVa:KB]
|
||||
}
|
||||
static LLCachedControl<bool> tear_off("OtherChatsTornOff");
|
||||
if (!tear_off) gIMMgr->setFloaterOpen(true);
|
||||
const std::string title = LLTrans::getString("conference-title");
|
||||
gIMMgr->addSession(title, IM_SESSION_CONFERENCE_START, ids[0], ids);
|
||||
make_ui_sound("UISndStartIM");
|
||||
}
|
||||
|
||||
/* Singu TODO: Web Profiles
|
||||
static const char* get_profile_floater_name(const LLUUID& avatar_id)
|
||||
{
|
||||
// Use different floater XML for our profile to be able to save its rect.
|
||||
return avatar_id == gAgentID ? "my_profile" : "profile";
|
||||
}
|
||||
*/
|
||||
|
||||
static void on_avatar_name_show_profile(const LLUUID& agent_id, const LLAvatarName& av_name)
|
||||
{
|
||||
//if (!gSavedSettings.getBOOL("UseWebProfiles")
|
||||
//{
|
||||
LLFloaterAvatarInfo* floater = LLFloaterAvatarInfo::getInstance(agent_id);
|
||||
if(!floater)
|
||||
{
|
||||
floater = new LLFloaterAvatarInfo(LLTrans::getString("Command_Profile_Label")+" "+av_name.getCompleteName(), agent_id);
|
||||
floater->center();
|
||||
}
|
||||
|
||||
// ...bring that window to front
|
||||
floater->open(); /*Flawfinder: ignore*/
|
||||
//}
|
||||
/*
|
||||
else
|
||||
{
|
||||
std::string username = av_name.mUsername;
|
||||
if (username.empty())
|
||||
{
|
||||
username = LLCacheName::buildUsername(av_name.mDisplayName);
|
||||
}
|
||||
|
||||
llinfos << "opening web profile for " << username << llendl;
|
||||
std::string url = getProfileURL(username);
|
||||
|
||||
// PROFILES: open in webkit window
|
||||
LLFloaterWebContent::Params p;
|
||||
p.url(url).
|
||||
id(agent_id.asString());
|
||||
LLFloaterReg::showInstance(get_profile_floater_name(agent_id), p);
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::showProfile(const LLUUID& id)
|
||||
{
|
||||
if (id.notNull())
|
||||
{
|
||||
LLAvatarName av_name;
|
||||
if (LLAvatarNameCache::get(id, &av_name)) // Bypass expiration, open NOW!
|
||||
on_avatar_name_show_profile(id, av_name);
|
||||
else
|
||||
LLAvatarNameCache::get(id, boost::bind(&on_avatar_name_show_profile, _1, _2));
|
||||
}
|
||||
}
|
||||
|
||||
//static
|
||||
bool LLAvatarActions::profileVisible(const LLUUID& id)
|
||||
{
|
||||
LLFloater* browser = getProfileFloater(id);
|
||||
return browser && browser->getVisible();
|
||||
}
|
||||
|
||||
//static
|
||||
LLFloater* LLAvatarActions::getProfileFloater(const LLUUID& id)
|
||||
{
|
||||
LLFloater* browser;
|
||||
//if (!gSavedSettings.getBOOL("UseWebProfiles")
|
||||
browser = LLFloaterAvatarInfo::getInstance(id);
|
||||
/*else
|
||||
browser = dynamic_cast<LLFloaterWebContent*>
|
||||
(LLFloaterReg::findInstance(get_profile_floater_name(id), LLSD().with("id", id)));
|
||||
*/
|
||||
return browser;
|
||||
}
|
||||
|
||||
//static
|
||||
void LLAvatarActions::hideProfile(const LLUUID& id)
|
||||
{
|
||||
LLFloater* browser = getProfileFloater(id);
|
||||
if (browser)
|
||||
{
|
||||
browser->close();
|
||||
}
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::showOnMap(const LLUUID& id)
|
||||
{
|
||||
std::string av_name;
|
||||
if (!LLAvatarNameCache::getPNSName(id, av_name))
|
||||
{
|
||||
LLAvatarNameCache::get(id, boost::bind(&LLAvatarActions::showOnMap, id));
|
||||
return;
|
||||
}
|
||||
|
||||
gFloaterWorldMap->trackAvatar(id, av_name);
|
||||
LLFloaterWorldMap::show(true);
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::pay(const LLUUID& id)
|
||||
{
|
||||
LLNotification::Params params("BusyModePay");
|
||||
params.functor(boost::bind(&LLAvatarActions::handlePay, _1, _2, id));
|
||||
|
||||
if (gAgent.getBusy())
|
||||
{
|
||||
// warn users of being in busy mode during a transaction
|
||||
LLNotifications::instance().add(params);
|
||||
}
|
||||
else
|
||||
{
|
||||
LLNotifications::instance().forceResponse(params, 1);
|
||||
}
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::kick(const LLUUID& id)
|
||||
{
|
||||
LLSD payload;
|
||||
payload["avatar_id"] = id;
|
||||
LLNotifications::instance().add("KickUser", LLSD(), payload, handleKick);
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::freeze(const LLUUID& id)
|
||||
{
|
||||
LLSD payload;
|
||||
payload["avatar_id"] = id;
|
||||
LLNotifications::instance().add("FreezeUser", LLSD(), payload, handleFreeze);
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::unfreeze(const LLUUID& id)
|
||||
{
|
||||
LLSD payload;
|
||||
payload["avatar_id"] = id;
|
||||
LLNotifications::instance().add("UnFreezeUser", LLSD(), payload, handleUnfreeze);
|
||||
}
|
||||
|
||||
//static
|
||||
void LLAvatarActions::csr(const LLUUID& id)
|
||||
{
|
||||
std::string name;
|
||||
if (!gCacheName->getFullName(id, name)) return;
|
||||
|
||||
std::string url = "http://csr.lindenlab.com/agent/";
|
||||
|
||||
// slow and stupid, but it's late
|
||||
S32 len = name.length();
|
||||
for (S32 i = 0; i < len; i++)
|
||||
{
|
||||
if (name[i] == ' ')
|
||||
{
|
||||
url += "%20";
|
||||
}
|
||||
else
|
||||
{
|
||||
url += name[i];
|
||||
}
|
||||
}
|
||||
|
||||
LLWeb::loadURL(url);
|
||||
}
|
||||
|
||||
// Singu TODO: Share inventory code block should live here
|
||||
|
||||
// static
|
||||
void LLAvatarActions::toggleBlock(const LLUUID& id)
|
||||
{
|
||||
std::string name;
|
||||
|
||||
gCacheName->getFullName(id, name); // needed for mute
|
||||
LLMute mute(id, name, LLMute::AGENT);
|
||||
|
||||
if (LLMuteList::getInstance()->isMuted(mute.mID, mute.mName))
|
||||
{
|
||||
LLMuteList::getInstance()->remove(mute);
|
||||
}
|
||||
else
|
||||
{
|
||||
LLMuteList::getInstance()->add(mute);
|
||||
}
|
||||
}
|
||||
|
||||
// static
|
||||
bool LLAvatarActions::canOfferTeleport(const LLUUID& id)
|
||||
{
|
||||
// First use LLAvatarTracker::isBuddy()
|
||||
// If LLAvatarTracker::instance().isBuddyOnline function only is used
|
||||
// then for avatars that are online and not a friend it will return false.
|
||||
// But we should give an ability to offer a teleport for such avatars.
|
||||
if(LLAvatarTracker::instance().isBuddy(id))
|
||||
{
|
||||
return LLAvatarTracker::instance().isBuddyOnline(id);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
// static
|
||||
bool LLAvatarActions::canOfferTeleport(const uuid_vec_t& ids)
|
||||
{
|
||||
// We can't send more than 250 lures in a single message, so disable this
|
||||
// button when there are too many id's selected.
|
||||
if(ids.size() > 250) return false;
|
||||
|
||||
bool result = true;
|
||||
for (uuid_vec_t::const_iterator it = ids.begin(); it != ids.end(); ++it)
|
||||
{
|
||||
if(!canOfferTeleport(*it))
|
||||
{
|
||||
result = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
void LLAvatarActions::inviteToGroup(const LLUUID& id)
|
||||
{
|
||||
LLFloaterGroupPicker* widget = LLFloaterGroupPicker::showInstance(LLSD(id));
|
||||
if (widget)
|
||||
{
|
||||
widget->center();
|
||||
widget->setPowersMask(GP_MEMBER_INVITE);
|
||||
//widget->removeNoneOption();
|
||||
widget->setSelectCallback(callback_invite_to_group, (void*)&id);
|
||||
}
|
||||
}
|
||||
|
||||
//== private methods ========================================================================================
|
||||
|
||||
// static
|
||||
bool LLAvatarActions::handleRemove(const LLSD& notification, const LLSD& response)
|
||||
{
|
||||
S32 option = LLNotificationsUtil::getSelectedOption(notification, response);
|
||||
|
||||
const LLSD& ids = notification["payload"]["ids"];
|
||||
for (LLSD::array_const_iterator itr = ids.beginArray(); itr != ids.endArray(); ++itr)
|
||||
{
|
||||
LLUUID id = itr->asUUID();
|
||||
const LLRelationship* ip = LLAvatarTracker::instance().getBuddyInfo(id);
|
||||
if (ip)
|
||||
{
|
||||
switch (option)
|
||||
{
|
||||
case 0: // YES
|
||||
if( ip->isRightGrantedTo(LLRelationship::GRANT_MODIFY_OBJECTS))
|
||||
{
|
||||
LLAvatarTracker::instance().empower(id, FALSE);
|
||||
LLAvatarTracker::instance().notifyObservers();
|
||||
}
|
||||
LLAvatarTracker::instance().terminateBuddy(id);
|
||||
LLAvatarTracker::instance().notifyObservers();
|
||||
gInventory.addChangedMask(LLInventoryObserver::LABEL | LLInventoryObserver::CALLING_CARD, LLUUID::null);
|
||||
gInventory.notifyObservers();
|
||||
break;
|
||||
|
||||
case 1: // NO
|
||||
default:
|
||||
llinfos << "No removal performed." << llendl;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
// static
|
||||
bool LLAvatarActions::handlePay(const LLSD& notification, const LLSD& response, LLUUID avatar_id)
|
||||
{
|
||||
S32 option = LLNotificationsUtil::getSelectedOption(notification, response);
|
||||
if (option == 0)
|
||||
{
|
||||
gAgent.clearBusy();
|
||||
}
|
||||
|
||||
LLFloaterPay::payDirectly(&give_money, avatar_id, /*is_group=*/false);
|
||||
return false;
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::callback_invite_to_group(LLUUID group_id, void* id)
|
||||
{
|
||||
uuid_vec_t agent_ids;
|
||||
agent_ids.push_back(*static_cast<const LLUUID*>(id));
|
||||
|
||||
LLFloaterGroupInvite::showForGroup(group_id, &agent_ids);
|
||||
}
|
||||
|
||||
|
||||
// static
|
||||
bool LLAvatarActions::callbackAddFriendWithMessage(const LLSD& notification, const LLSD& response)
|
||||
{
|
||||
S32 option = LLNotificationsUtil::getSelectedOption(notification, response);
|
||||
if (option == 0)
|
||||
{
|
||||
requestFriendship(notification["payload"]["id"].asUUID(),
|
||||
notification["payload"]["name"].asString(),
|
||||
response["message"].asString());
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
// static
|
||||
bool LLAvatarActions::handleKick(const LLSD& notification, const LLSD& response)
|
||||
{
|
||||
S32 option = LLNotification::getSelectedOption(notification, response);
|
||||
|
||||
if (option == 0)
|
||||
{
|
||||
LLUUID avatar_id = notification["payload"]["avatar_id"].asUUID();
|
||||
LLMessageSystem* msg = gMessageSystem;
|
||||
|
||||
msg->newMessageFast(_PREHASH_GodKickUser);
|
||||
msg->nextBlockFast(_PREHASH_UserInfo);
|
||||
msg->addUUIDFast(_PREHASH_GodID, gAgent.getID() );
|
||||
msg->addUUIDFast(_PREHASH_GodSessionID, gAgent.getSessionID());
|
||||
msg->addUUIDFast(_PREHASH_AgentID, avatar_id );
|
||||
msg->addU32("KickFlags", KICK_FLAGS_DEFAULT );
|
||||
msg->addStringFast(_PREHASH_Reason, response["message"].asString() );
|
||||
gAgent.sendReliableMessage();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
bool LLAvatarActions::handleFreeze(const LLSD& notification, const LLSD& response)
|
||||
{
|
||||
S32 option = LLNotification::getSelectedOption(notification, response);
|
||||
|
||||
if (option == 0)
|
||||
{
|
||||
LLUUID avatar_id = notification["payload"]["avatar_id"].asUUID();
|
||||
LLMessageSystem* msg = gMessageSystem;
|
||||
|
||||
msg->newMessageFast(_PREHASH_GodKickUser);
|
||||
msg->nextBlockFast(_PREHASH_UserInfo);
|
||||
msg->addUUIDFast(_PREHASH_GodID, gAgent.getID() );
|
||||
msg->addUUIDFast(_PREHASH_GodSessionID, gAgent.getSessionID());
|
||||
msg->addUUIDFast(_PREHASH_AgentID, avatar_id );
|
||||
msg->addU32("KickFlags", KICK_FLAGS_FREEZE );
|
||||
msg->addStringFast(_PREHASH_Reason, response["message"].asString() );
|
||||
gAgent.sendReliableMessage();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
bool LLAvatarActions::handleUnfreeze(const LLSD& notification, const LLSD& response)
|
||||
{
|
||||
S32 option = LLNotification::getSelectedOption(notification, response);
|
||||
std::string text = response["message"].asString();
|
||||
if (option == 0)
|
||||
{
|
||||
LLUUID avatar_id = notification["payload"]["avatar_id"].asUUID();
|
||||
LLMessageSystem* msg = gMessageSystem;
|
||||
|
||||
msg->newMessageFast(_PREHASH_GodKickUser);
|
||||
msg->nextBlockFast(_PREHASH_UserInfo);
|
||||
msg->addUUIDFast(_PREHASH_GodID, gAgent.getID() );
|
||||
msg->addUUIDFast(_PREHASH_GodSessionID, gAgent.getSessionID());
|
||||
msg->addUUIDFast(_PREHASH_AgentID, avatar_id );
|
||||
msg->addU32("KickFlags", KICK_FLAGS_UNFREEZE );
|
||||
msg->addStringFast(_PREHASH_Reason, text );
|
||||
gAgent.sendReliableMessage();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
// static
|
||||
void LLAvatarActions::requestFriendship(const LLUUID& target_id, const std::string& target_name, const std::string& message)
|
||||
{
|
||||
const LLUUID calling_card_folder_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_CALLINGCARD);
|
||||
send_improved_im(target_id,
|
||||
target_name,
|
||||
message,
|
||||
IM_ONLINE,
|
||||
IM_FRIENDSHIP_OFFERED,
|
||||
calling_card_folder_id);
|
||||
|
||||
LLSD args;
|
||||
args["TO_NAME"] = target_name;
|
||||
|
||||
LLSD payload;
|
||||
payload["from_id"] = target_id;
|
||||
//payload["SUPPRESS_TOAST"] = true;
|
||||
LLNotificationsUtil::add("FriendshipOffered", args, payload);
|
||||
}
|
||||
|
||||
//static
|
||||
bool LLAvatarActions::isFriend(const LLUUID& id)
|
||||
{
|
||||
return ( NULL != LLAvatarTracker::instance().getBuddyInfo(id) );
|
||||
}
|
||||
|
||||
// static
|
||||
bool LLAvatarActions::isBlocked(const LLUUID& id)
|
||||
{
|
||||
return LLMuteList::getInstance()->isMuted(id);
|
||||
}
|
||||
|
||||
// static
|
||||
bool LLAvatarActions::canBlock(const LLUUID& id)
|
||||
{
|
||||
bool is_linden = LLMuteList::getInstance()->isLinden(id);
|
||||
bool is_self = id == gAgentID;
|
||||
return !is_self && !is_linden;
|
||||
}
|
||||
|
||||
188
indra/newview/llavataractions.h
Normal file
188
indra/newview/llavataractions.h
Normal file
@@ -0,0 +1,188 @@
|
||||
/**
|
||||
* @file llavataractions.h
|
||||
* @brief Friend-related actions (add, remove, offer teleport, etc)
|
||||
*
|
||||
* $LicenseInfo:firstyear=2009&license=viewerlgpl$
|
||||
* Second Life Viewer Source Code
|
||||
* Copyright (C) 2010, Linden Research, Inc.
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation;
|
||||
* version 2.1 of the License only.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*
|
||||
* Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
|
||||
* $/LicenseInfo$
|
||||
*/
|
||||
|
||||
#ifndef LL_LLAVATARACTIONS_H
|
||||
#define LL_LLAVATARACTIONS_H
|
||||
|
||||
class LLFloater;
|
||||
|
||||
/**
|
||||
* Friend-related actions (add, remove, offer teleport, etc)
|
||||
*/
|
||||
class LLAvatarActions
|
||||
{
|
||||
public:
|
||||
/**
|
||||
* Show a dialog explaining what friendship entails, then request friendship.
|
||||
*/
|
||||
static void requestFriendshipDialog(const LLUUID& id, const std::string& name);
|
||||
|
||||
/**
|
||||
* Show a dialog explaining what friendship entails, then request friendship.
|
||||
*/
|
||||
static void requestFriendshipDialog(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* Show a friend removal dialog.
|
||||
*/
|
||||
static void removeFriendDialog(const LLUUID& id);
|
||||
static void removeFriendsDialog(const uuid_vec_t& ids);
|
||||
|
||||
/**
|
||||
* Show teleport offer dialog.
|
||||
*/
|
||||
static void offerTeleport(const LLUUID& invitee);
|
||||
static void offerTeleport(const uuid_vec_t& ids);
|
||||
|
||||
/**
|
||||
* Start instant messaging session.
|
||||
*/
|
||||
static void startIM(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* End instant messaging session.
|
||||
*/
|
||||
static void endIM(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* Start an avatar-to-avatar voice call with another user
|
||||
*/
|
||||
static void startCall(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* Start an ad-hoc conference voice call with multiple users
|
||||
*/
|
||||
static void startAdhocCall(const uuid_vec_t& ids);
|
||||
|
||||
/**
|
||||
* Start conference chat with the given avatars.
|
||||
*/
|
||||
static void startConference(const uuid_vec_t& ids);
|
||||
|
||||
/**
|
||||
* Show avatar profile.
|
||||
*/
|
||||
static void showProfile(const LLUUID& id);
|
||||
static void hideProfile(const LLUUID& id);
|
||||
static bool profileVisible(const LLUUID& id);
|
||||
static LLFloater* getProfileFloater(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* Show avatar on world map.
|
||||
*/
|
||||
static void showOnMap(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* Give money to the avatar.
|
||||
*/
|
||||
static void pay(const LLUUID& id);
|
||||
/**
|
||||
* Block/unblock the avatar.
|
||||
*/
|
||||
static void toggleBlock(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* Return true if avatar with "id" is a friend
|
||||
*/
|
||||
static bool isFriend(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* @return true if the avatar is blocked
|
||||
*/
|
||||
static bool isBlocked(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* @return true if you can block the avatar
|
||||
*/
|
||||
static bool canBlock(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* Return true if the avatar is in a P2P voice call with a given user
|
||||
*/
|
||||
/* AD *TODO: Is this function needed any more?
|
||||
I fixed it a bit(added check for canCall), but it appears that it is not used
|
||||
anywhere. Maybe it should be removed?
|
||||
static bool isCalling(const LLUUID &id);*/
|
||||
|
||||
/**
|
||||
* @return true if call to the resident can be made
|
||||
*/
|
||||
|
||||
static bool canCall();
|
||||
/**
|
||||
* Invite avatar to a group.
|
||||
*/
|
||||
static void inviteToGroup(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* Kick avatar off grid
|
||||
*/
|
||||
static void kick(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* Freeze avatar
|
||||
*/
|
||||
static void freeze(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* Unfreeze avatar
|
||||
*/
|
||||
static void unfreeze(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* Open csr page for avatar
|
||||
*/
|
||||
static void csr(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* Checks whether we can offer a teleport to the avatar, only offline friends
|
||||
* cannot be offered a teleport.
|
||||
*
|
||||
* @return false if avatar is a friend and not visibly online
|
||||
*/
|
||||
static bool canOfferTeleport(const LLUUID& id);
|
||||
|
||||
/**
|
||||
* @return false if any one of the specified avatars a friend and not visibly online
|
||||
*/
|
||||
static bool canOfferTeleport(const uuid_vec_t& ids);
|
||||
|
||||
private:
|
||||
static bool callbackAddFriendWithMessage(const LLSD& notification, const LLSD& response);
|
||||
static bool handleRemove(const LLSD& notification, const LLSD& response);
|
||||
static bool handlePay(const LLSD& notification, const LLSD& response, LLUUID avatar_id);
|
||||
static bool handleKick(const LLSD& notification, const LLSD& response);
|
||||
static bool handleFreeze(const LLSD& notification, const LLSD& response);
|
||||
static bool handleUnfreeze(const LLSD& notification, const LLSD& response);
|
||||
static void callback_invite_to_group(LLUUID group_id, void* id);
|
||||
|
||||
public:
|
||||
// Just request friendship, no dialog.
|
||||
static void requestFriendship(const LLUUID& target_id, const std::string& target_name, const std::string& message);
|
||||
};
|
||||
|
||||
#endif // LL_LLAVATARACTIONS_H
|
||||
|
||||
@@ -36,27 +36,24 @@
|
||||
|
||||
#include "llagent.h"
|
||||
#include "llappviewer.h"
|
||||
#include "llimview.h"
|
||||
#include "llsdutil.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "lluictrlfactory.h"
|
||||
#include "llviewercontrol.h"
|
||||
#include "llscrolllistctrl.h"
|
||||
#include "llavataractions.h"
|
||||
#include "llbutton.h"
|
||||
#include "lltextbox.h"
|
||||
#include "llmutelist.h"
|
||||
#include "llviewerobjectlist.h"
|
||||
#include "llvoavatar.h"
|
||||
#include "llimpanel.h" // LLVoiceChannel
|
||||
#include "llimview.h"
|
||||
#include "llmutelist.h"
|
||||
#include "llscrolllistctrl.h"
|
||||
#include "llsdutil.h"
|
||||
#include "lltextbox.h"
|
||||
#include "lluictrlfactory.h"
|
||||
#include "llviewerobjectlist.h"
|
||||
#include "llviewerwindow.h"
|
||||
#include "llvoavatar.h"
|
||||
#include "llworld.h"
|
||||
|
||||
// [RLVa:KB]
|
||||
#include "rlvhandler.h"
|
||||
// [/RLVa:KB]
|
||||
|
||||
#include "llavatarname.h"
|
||||
|
||||
class AIHTTPTimeoutPolicy;
|
||||
extern AIHTTPTimeoutPolicy muteVoiceResponder_timeout;
|
||||
extern AIHTTPTimeoutPolicy muteTextResponder_timeout;
|
||||
@@ -770,32 +767,14 @@ void LLPanelActiveSpeakers::onClickProfile(void* user_data)
|
||||
// [/RLVa:KB]
|
||||
|
||||
LLPanelActiveSpeakers* panelp = (LLPanelActiveSpeakers*)user_data;
|
||||
LLUUID speaker_id = panelp->mSpeakerList->getValue().asUUID();
|
||||
|
||||
LLFloaterAvatarInfo::showFromDirectory(speaker_id);
|
||||
LLAvatarActions::showProfile(panelp->mSpeakerList->getValue().asUUID());
|
||||
}
|
||||
|
||||
//static
|
||||
void LLPanelActiveSpeakers::onDoubleClickSpeaker(void* user_data)
|
||||
{
|
||||
// [RLVa:KB] - Checked: 2009-07-10 (RLVa-1.0.0g) | Added: RLVa-1.0.0g
|
||||
if (gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES))
|
||||
{
|
||||
return;
|
||||
}
|
||||
// [/RLVa:KB]
|
||||
|
||||
LLPanelActiveSpeakers* panelp = (LLPanelActiveSpeakers*)user_data;
|
||||
LLUUID speaker_id = panelp->mSpeakerList->getValue().asUUID();
|
||||
|
||||
LLPointer<LLSpeaker> speakerp = panelp->mSpeakerMgr->findSpeaker(speaker_id);
|
||||
|
||||
if (speaker_id != gAgent.getID() && speakerp.notNull() && !speakerp->mLegacyName.empty())
|
||||
{
|
||||
// Changed for display name support
|
||||
//gIMMgr->addSession(speakerp->mDisplayName, IM_NOTHING_SPECIAL, speaker_id);
|
||||
gIMMgr->addSession(speakerp->mLegacyName, IM_NOTHING_SPECIAL, speaker_id);
|
||||
}
|
||||
LLAvatarActions::startIM(panelp->mSpeakerList->getValue().asUUID());
|
||||
}
|
||||
|
||||
//static
|
||||
|
||||
@@ -35,168 +35,26 @@
|
||||
#include "llviewerprecompiledheaders.h"
|
||||
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "llavatarnamecache.h"
|
||||
|
||||
// viewer project includes
|
||||
#include "llagentdata.h"
|
||||
#include "llcommandhandler.h"
|
||||
#include "llimview.h"
|
||||
#include "llfloaterfriends.h"
|
||||
#include "llfloatermute.h"
|
||||
#include "llmenucommands.h"
|
||||
#include "llpanelavatar.h"
|
||||
#include "llviewermessage.h"
|
||||
#include "lluictrlfactory.h"
|
||||
#include "llweb.h"
|
||||
|
||||
// linden library includes
|
||||
#include "llinventory.h"
|
||||
#include "lluuid.h"
|
||||
#include "message.h"
|
||||
|
||||
|
||||
const char FLOATER_TITLE[] = "Profile";
|
||||
const LLRect FAI_RECT(0, 530, 420, 0);
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Globals
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
class LLAgentHandler : public LLCommandHandler
|
||||
{
|
||||
public:
|
||||
void verbCallback(const std::string& verb, LLUUID agent_id, const LLAvatarName& avatar_name)
|
||||
{
|
||||
if (verb == "im")
|
||||
{
|
||||
gIMMgr->setFloaterOpen(TRUE);
|
||||
gIMMgr->addSession( avatar_name.getCompleteName(), IM_NOTHING_SPECIAL, agent_id);
|
||||
return;
|
||||
}
|
||||
|
||||
if (verb == "requestfriend")
|
||||
{
|
||||
LLPanelFriends::requestFriendshipDialog( agent_id, avatar_name.getCompleteName() );
|
||||
return;
|
||||
}
|
||||
|
||||
if (verb == "mute")
|
||||
{
|
||||
LLFloaterMute::getInstance()->open();
|
||||
LLMute mute(agent_id, avatar_name.getCompleteName(), LLMute::AGENT);
|
||||
LLMuteList::getInstance()->add(mute);
|
||||
return;
|
||||
}
|
||||
|
||||
if (verb == "unmute")
|
||||
{
|
||||
LLMute mute(agent_id, avatar_name.getCompleteName(), LLMute::AGENT);
|
||||
LLMuteList::getInstance()->remove(mute);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
// requires trusted browser to trigger
|
||||
LLAgentHandler() : LLCommandHandler("agent", true) { }
|
||||
|
||||
bool handle(const LLSD& params, const LLSD& query_map,
|
||||
LLMediaCtrl* web)
|
||||
{
|
||||
if (params.size() < 2)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
LLUUID agent_id;
|
||||
if (!agent_id.set(params[0], FALSE))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
const std::string verb = params[1].asString();
|
||||
if (verb == "about")
|
||||
{
|
||||
LLFloaterAvatarInfo::show(agent_id);
|
||||
return true;
|
||||
}
|
||||
|
||||
if (verb == "pay")
|
||||
{
|
||||
handle_pay_by_id(agent_id);
|
||||
return true;
|
||||
}
|
||||
|
||||
if (verb == "offerteleport")
|
||||
{
|
||||
handle_lure(agent_id);
|
||||
return true;
|
||||
}
|
||||
|
||||
if ((verb == "im") || (verb == "requestfriend") || (verb == "unmute"))
|
||||
{
|
||||
LLAvatarNameCache::get(agent_id, boost::bind(&LLAgentHandler::verbCallback, this, verb, _1, _2));
|
||||
return true;
|
||||
}
|
||||
|
||||
if (verb == "mute")
|
||||
{
|
||||
if (LLMuteList::getInstance()->isMuted(agent_id))
|
||||
{
|
||||
LLFloaterMute::getInstance()->open();
|
||||
LLFloaterMute::getInstance()->selectMute(agent_id);
|
||||
}
|
||||
else
|
||||
{
|
||||
LLAvatarNameCache::get(agent_id, boost::bind(&LLAgentHandler::verbCallback, this, verb, _1, _2));
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
};
|
||||
LLAgentHandler gAgentHandler;
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Member functions
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
|
||||
void* LLFloaterAvatarInfo::createPanelAvatar(void* data)
|
||||
{
|
||||
LLFloaterAvatarInfo* self = (LLFloaterAvatarInfo*)data;
|
||||
self->mPanelAvatarp = new LLPanelAvatar("PanelAv", LLRect(), TRUE); // allow edit self
|
||||
self->mPanelAvatarp->setAvatarID(self->mAvatarID);
|
||||
return self->mPanelAvatarp;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
|
||||
|
||||
BOOL LLFloaterAvatarInfo::postBuild()
|
||||
LLFloaterAvatarInfo::LLFloaterAvatarInfo(const std::string& name, const LLUUID &avatar_id)
|
||||
: LLFloater(name), LLInstanceTracker<LLFloaterAvatarInfo, LLUUID>(avatar_id),
|
||||
mAvatarID(avatar_id)
|
||||
{
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
LLFloaterAvatarInfo::LLFloaterAvatarInfo(const std::string& name, const LLRect &rect, const LLUUID &avatar_id)
|
||||
: LLPreview(name, rect, FLOATER_TITLE, LLUUID::null, LLUUID::null), LLInstanceTracker<LLFloaterAvatarInfo, LLUUID>(avatar_id),
|
||||
mAvatarID( avatar_id ),
|
||||
mSuggestedOnlineStatus(ONLINE_STATUS_NO)
|
||||
{
|
||||
setAutoFocus(TRUE);
|
||||
setAutoFocus(true);
|
||||
|
||||
LLCallbackMap::map_t factory_map;
|
||||
|
||||
factory_map["Panel Avatar"] = LLCallbackMap(createPanelAvatar, this);
|
||||
|
||||
LLUICtrlFactory::getInstance()->buildFloater(this, "floater_profile.xml", &factory_map);
|
||||
|
||||
if(mPanelAvatarp)
|
||||
{
|
||||
mPanelAvatarp->selectTab(0);
|
||||
}
|
||||
|
||||
//gCacheName->get(avatar_id, FALSE, callbackLoadAvatarName);
|
||||
LLAvatarNameCache::get(avatar_id, boost::bind(&LLFloaterAvatarInfo::callbackLoadAvatarName, this, _1, _2));
|
||||
}
|
||||
|
||||
// virtual
|
||||
@@ -206,131 +64,11 @@ LLFloaterAvatarInfo::~LLFloaterAvatarInfo()
|
||||
|
||||
void LLFloaterAvatarInfo::resetGroupList()
|
||||
{
|
||||
// only get these updates asynchronously via the group floater, which works on the agent only
|
||||
if (mAvatarID != gAgentID)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
mPanelAvatarp->resetGroupList();
|
||||
}
|
||||
|
||||
// static
|
||||
LLFloaterAvatarInfo* LLFloaterAvatarInfo::show(const LLUUID &avatar_id)
|
||||
{
|
||||
if (avatar_id.isNull())
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
||||
LLFloaterAvatarInfo *floater = LLFloaterAvatarInfo::getInstance(avatar_id);
|
||||
if(!floater)
|
||||
{
|
||||
floater = new LLFloaterAvatarInfo("avatarinfo", FAI_RECT, avatar_id );
|
||||
floater->center();
|
||||
}
|
||||
|
||||
// ...bring that window to front
|
||||
floater->open(); /*Flawfinder: ignore*/
|
||||
return floater;
|
||||
}
|
||||
|
||||
// Open profile to a certain tab.
|
||||
// static
|
||||
void LLFloaterAvatarInfo::showFromObject(const LLUUID& avatar_id,std::string tab_name)
|
||||
{
|
||||
LLFloaterAvatarInfo *floater = show(avatar_id);
|
||||
if (floater)
|
||||
{
|
||||
floater->mPanelAvatarp->setAvatarID(avatar_id, LLStringUtil::null, ONLINE_STATUS_NO);
|
||||
floater->mPanelAvatarp->selectTabByName(tab_name);
|
||||
}
|
||||
}
|
||||
|
||||
// static
|
||||
void LLFloaterAvatarInfo::showFromDirectory(const LLUUID &avatar_id)
|
||||
{
|
||||
LLFloaterAvatarInfo *floater = show(avatar_id);
|
||||
if (floater)
|
||||
{
|
||||
floater->mPanelAvatarp->setAvatarID(avatar_id, LLStringUtil::null, ONLINE_STATUS_NO);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// static
|
||||
void LLFloaterAvatarInfo::showFromFriend(const LLUUID& agent_id, BOOL online)
|
||||
{
|
||||
LLFloaterAvatarInfo *floater = show(agent_id);
|
||||
if (floater)
|
||||
{
|
||||
floater->mSuggestedOnlineStatus = online ? ONLINE_STATUS_YES : ONLINE_STATUS_NO;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// static
|
||||
void LLFloaterAvatarInfo::showFromProfile(const LLUUID &avatar_id, LLRect rect)
|
||||
{
|
||||
if (avatar_id.isNull())
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
LLFloaterAvatarInfo *floater = LLFloaterAvatarInfo::getInstance(avatar_id);
|
||||
if(!floater)
|
||||
{
|
||||
floater = new LLFloaterAvatarInfo("avatarinfo", FAI_RECT, avatar_id);
|
||||
floater->translate(rect.mLeft - floater->getRect().mLeft + 16,
|
||||
rect.mTop - floater->getRect().mTop - 16);
|
||||
floater->mPanelAvatarp->setAvatarID(avatar_id, LLStringUtil::null, ONLINE_STATUS_NO);
|
||||
}
|
||||
floater->open();
|
||||
}
|
||||
|
||||
void LLFloaterAvatarInfo::showProfileCallback(S32 option, void *userdata)
|
||||
{
|
||||
if (option == 0)
|
||||
{
|
||||
showFromObject(gAgentID);
|
||||
}
|
||||
}
|
||||
|
||||
void LLFloaterAvatarInfo::callbackLoadAvatarName(const LLUUID& id, const LLAvatarName& av_name)
|
||||
{
|
||||
// Build a new title including the avatar name.
|
||||
std::ostringstream title;
|
||||
//title << first << " " << last << " - " << floater->getTitle();
|
||||
title << av_name.getCompleteName()<< " - " << getTitle();
|
||||
setTitle(title.str());
|
||||
}
|
||||
|
||||
//// virtual
|
||||
void LLFloaterAvatarInfo::draw()
|
||||
{
|
||||
// skip LLPreview::draw()
|
||||
LLFloater::draw();
|
||||
}
|
||||
|
||||
// virtual
|
||||
BOOL LLFloaterAvatarInfo::canClose()
|
||||
{
|
||||
return mPanelAvatarp && mPanelAvatarp->canClose();
|
||||
}
|
||||
|
||||
void LLFloaterAvatarInfo::loadAsset()
|
||||
{
|
||||
if (mPanelAvatarp) {
|
||||
mPanelAvatarp->setAvatarID(mAvatarID, LLStringUtil::null, mSuggestedOnlineStatus);
|
||||
mAssetStatus = PREVIEW_ASSET_LOADING;
|
||||
}
|
||||
}
|
||||
|
||||
LLPreview::EAssetStatus LLFloaterAvatarInfo::getAssetStatus()
|
||||
{
|
||||
if (mPanelAvatarp && mPanelAvatarp->haveData())
|
||||
{
|
||||
mAssetStatus = PREVIEW_ASSET_LOADED;
|
||||
}
|
||||
return mAssetStatus;
|
||||
}
|
||||
|
||||
@@ -40,66 +40,24 @@
|
||||
#define LL_LLFLOATERAVATARINFO_H
|
||||
|
||||
#include "llfloater.h"
|
||||
#include "llpreview.h"
|
||||
#include "lluuid.h"
|
||||
#include "llpanelavatar.h"
|
||||
#include "llinstancetracker.h"
|
||||
|
||||
class LLAvatarName;
|
||||
class LLButton;
|
||||
class LLCheckBoxCtrl;
|
||||
class LLInventoryItem;
|
||||
class LLLineEditor;
|
||||
class LLMessageSystem;
|
||||
class LLScrollListCtrl;
|
||||
class LLTabContainer;
|
||||
class LLTextBox;
|
||||
class LLTextEditor;
|
||||
class LLTextureCtrl;
|
||||
class LLUICtrl;
|
||||
class LLViewerTexture;
|
||||
class LLViewerObject;
|
||||
class LLPanelAvatar;
|
||||
|
||||
class LLFloaterAvatarInfo
|
||||
: public LLPreview, public LLInstanceTracker<LLFloaterAvatarInfo,LLUUID>
|
||||
: public LLFloater, public LLInstanceTracker<LLFloaterAvatarInfo,LLUUID>
|
||||
{
|
||||
public:
|
||||
static void* createPanelAvatar(void* data);
|
||||
|
||||
virtual BOOL postBuild();
|
||||
|
||||
LLFloaterAvatarInfo(const std::string& name, const LLRect &rect, const LLUUID &avatar_id );
|
||||
LLFloaterAvatarInfo(const std::string& name, const LLUUID &avatar_id);
|
||||
/*virtual*/ ~LLFloaterAvatarInfo();
|
||||
|
||||
/*virtual*/ void draw();
|
||||
|
||||
/*virtual*/ BOOL canClose();
|
||||
|
||||
/*virtual*/ void loadAsset();
|
||||
/*virtual*/ EAssetStatus getAssetStatus();
|
||||
|
||||
static LLFloaterAvatarInfo* show(const LLUUID& avatar_id);
|
||||
// Core method, doesn't do anything funny with online status or
|
||||
// tab selection.
|
||||
|
||||
static void showFromObject(const LLUUID &avatar_id, std::string tab_name = std::string());
|
||||
|
||||
static void showFromDirectory(const LLUUID &avatar_id);
|
||||
|
||||
static void showFromFriend(const LLUUID &agent_id, BOOL online);
|
||||
|
||||
static void showFromProfile(const LLUUID &avatar_id, LLRect rect);
|
||||
|
||||
static void showProfileCallback(S32 option, void *userdata);
|
||||
void callbackLoadAvatarName(const LLUUID& agent_id, const LLAvatarName& av_name);
|
||||
void resetGroupList();
|
||||
|
||||
private:
|
||||
LLUUID mAvatarID; // for which avatar is this window?
|
||||
LLPanelAvatar* mPanelAvatarp;
|
||||
EOnlineStatus mSuggestedOnlineStatus;
|
||||
};
|
||||
|
||||
std::string getProfileURL(const std::string& agent_name);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -25,21 +25,17 @@
|
||||
#include "llwindow.h"
|
||||
#include "llscrolllistctrl.h"
|
||||
#include "llradiogroup.h"
|
||||
#include "llviewercontrol.h"
|
||||
#include "llnotificationsutil.h"
|
||||
|
||||
#include "llvoavatar.h"
|
||||
#include "llimview.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "llregionflags.h"
|
||||
#include "llfloaterreporter.h"
|
||||
#include "llagent.h"
|
||||
#include "llagentcamera.h"
|
||||
#include "llavataractions.h"
|
||||
#include "llfloaterregioninfo.h"
|
||||
#include "llviewerregion.h"
|
||||
#include "lltracker.h"
|
||||
#include "llviewerstats.h"
|
||||
#include "llerror.h"
|
||||
#include "llchat.h"
|
||||
#include "llfloaterchat.h"
|
||||
#include "llviewermessage.h"
|
||||
@@ -882,7 +878,7 @@ void LLFloaterAvatarList::refreshAvatarList()
|
||||
name_color = ascent_estate_owner_color;
|
||||
}
|
||||
//without these dots, SL would suck.
|
||||
else if(is_agent_friend(av_id))
|
||||
else if(LLAvatarActions::isFriend(av_id))
|
||||
{
|
||||
static const LLCachedControl<LLColor4> ascent_friend_color("AscentFriendColor",LLColor4(1.f,1.f,0.f,1.f));
|
||||
name_color = ascent_friend_color;
|
||||
@@ -1142,22 +1138,12 @@ void LLFloaterAvatarList::onClickIM()
|
||||
if (ids.size() == 1)
|
||||
{
|
||||
// Single avatar
|
||||
LLUUID agent_id = ids[0];
|
||||
|
||||
std::string avatar_name;
|
||||
if (gCacheName->getFullName(agent_id, avatar_name))
|
||||
{
|
||||
gIMMgr->setFloaterOpen(TRUE);
|
||||
gIMMgr->addSession(avatar_name,IM_NOTHING_SPECIAL,agent_id);
|
||||
}
|
||||
LLAvatarActions::startIM(ids[0]);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Group IM
|
||||
LLUUID session_id;
|
||||
session_id.generate();
|
||||
gIMMgr->setFloaterOpen(TRUE);
|
||||
gIMMgr->addSession("Avatars Conference", IM_SESSION_CONFERENCE_START, ids[0], ids);
|
||||
LLAvatarActions::startConference(ids);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1265,30 +1251,7 @@ BOOL LLFloaterAvatarList::handleKeyHere(KEY key, MASK mask)
|
||||
|
||||
if (( KEY_RETURN == key ) && (MASK_SHIFT == mask))
|
||||
{
|
||||
uuid_vec_t ids = mAvatarList->getSelectedIDs();
|
||||
if (ids.size() > 0)
|
||||
{
|
||||
if (ids.size() == 1)
|
||||
{
|
||||
// Single avatar
|
||||
LLUUID agent_id = ids[0];
|
||||
|
||||
std::string avatar_name;
|
||||
if (gCacheName->getFullName(agent_id, avatar_name))
|
||||
{
|
||||
gIMMgr->setFloaterOpen(TRUE);
|
||||
gIMMgr->addSession(avatar_name,IM_NOTHING_SPECIAL,agent_id);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Group IM
|
||||
LLUUID session_id;
|
||||
session_id.generate();
|
||||
gIMMgr->setFloaterOpen(TRUE);
|
||||
gIMMgr->addSession("Avatars Conference", IM_SESSION_CONFERENCE_START, ids[0], ids);
|
||||
}
|
||||
}
|
||||
onClickIM();
|
||||
}
|
||||
return LLPanel::handleKeyHere(key, mask);
|
||||
}
|
||||
@@ -1553,7 +1516,7 @@ static void cmd_append_names(const LLAvatarListEntry* entry, std::string &str, s
|
||||
{ if(!str.empty())str.append(sep);str.append(entry->getName()); }
|
||||
static void cmd_toggle_mark(LLAvatarListEntry* entry) { entry->toggleMark(); }
|
||||
static void cmd_ar(const LLAvatarListEntry* entry) { LLFloaterReporter::showFromObject(entry->getID()); }
|
||||
static void cmd_profile(const LLAvatarListEntry* entry) { LLFloaterAvatarInfo::showFromDirectory(entry->getID()); }
|
||||
static void cmd_profile(const LLAvatarListEntry* entry) { LLAvatarActions::showProfile(entry->getID()); }
|
||||
static void cmd_teleport(const LLAvatarListEntry* entry) { gAgent.teleportViaLocation(entry->getPosition()); }
|
||||
static void cmd_freeze(const LLAvatarListEntry* entry) { send_freeze(entry->getID(), true); }
|
||||
static void cmd_unfreeze(const LLAvatarListEntry* entry) { send_freeze(entry->getID(), false); }
|
||||
|
||||
@@ -557,7 +557,10 @@ BOOL LLFloaterAvatarPicker::handleDragAndDrop(S32 x, S32 y, MASK mask,
|
||||
std::string avatar_name = selection->getColumn(0)->getValue().asString();
|
||||
if (dest_agent_id.notNull() && dest_agent_id != gAgentID)
|
||||
{
|
||||
if (drop)
|
||||
// if (drop)
|
||||
// [RLVa:KB] - Checked: 2011-04-11 (RLVa-1.3.0h) | Added: RLVa-1.3.0h
|
||||
if ( (drop) && ( (!rlv_handler_t::isEnabled()) || (gRlvHandler.canStartIM(dest_agent_id)) ) )
|
||||
// [/RLVa:KB]
|
||||
{
|
||||
// Start up IM before give the item
|
||||
session_id = gIMMgr->addSession(avatar_name, IM_NOTHING_SPECIAL, dest_agent_id);
|
||||
|
||||
@@ -37,46 +37,31 @@
|
||||
|
||||
#include "llfloaterfriends.h"
|
||||
|
||||
#include <sstream>
|
||||
|
||||
#include "lldir.h"
|
||||
|
||||
#include "llagent.h"
|
||||
#include "llappviewer.h" // for gLastVersionChannel
|
||||
|
||||
#include "llavataractions.h"
|
||||
#include "llavatarnamecache.h"
|
||||
|
||||
#include "llfloateravatarpicker.h"
|
||||
#include "llviewerwindow.h"
|
||||
#include "llbutton.h"
|
||||
#include "lldir.h"
|
||||
#include "lleventtimer.h"
|
||||
#include "llfiltereditor.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "llinventorymodel.h"
|
||||
#include "llfloateravatarpicker.h"
|
||||
#include "llnamelistctrl.h"
|
||||
#include "llnotificationsutil.h"
|
||||
#include "llresmgr.h"
|
||||
#include "llimview.h"
|
||||
#include "lluictrlfactory.h"
|
||||
#include "llmenucommands.h"
|
||||
#include "llviewercontrol.h"
|
||||
#include "llviewermessage.h"
|
||||
#include "lleventtimer.h"
|
||||
#include "llsdserialize.h"
|
||||
#include "lltextbox.h"
|
||||
#include "lluictrlfactory.h"
|
||||
#include "llviewerwindow.h"
|
||||
#include "llvoiceclient.h"
|
||||
|
||||
#include "llsdserialize.h"
|
||||
#include "statemachine/aifilepicker.h"
|
||||
|
||||
#include "llviewermenufile.h"
|
||||
#include "llviewermenu.h"
|
||||
#include "llviewernetwork.h"
|
||||
#include "hippogridmanager.h"
|
||||
|
||||
#include "llchat.h"
|
||||
#include "llfloaterchat.h"
|
||||
|
||||
// <dogmode> stuff for Contact groups
|
||||
//#include "ascentfloatercontactgroups.h"
|
||||
//#include "llchat.h"
|
||||
//#include "llfloaterchat.h"
|
||||
|
||||
#define DEFAULT_PERIOD 5.0
|
||||
#define RIGHTS_CHANGE_TIMEOUT 5.0
|
||||
@@ -399,10 +384,10 @@ BOOL LLPanelFriends::postBuild()
|
||||
//childSetAction("assign_btn", onClickAssign, this);
|
||||
childSetAction("expand_collapse_btn", onClickExpand, this);
|
||||
childSetAction("profile_btn", onClickProfile, this);
|
||||
childSetAction("offer_teleport_btn", onClickOfferTeleport, this);
|
||||
getChild<LLUICtrl>("offer_teleport_btn")->setCommitCallback(boost::bind(static_cast<void(*)(const uuid_vec_t&)>(LLAvatarActions::offerTeleport), boost::bind(&LLScrollListCtrl::getSelectedIDs, mFriendsList)));
|
||||
childSetAction("pay_btn", onClickPay, this);
|
||||
childSetAction("add_btn", onClickAddFriend, this);
|
||||
childSetAction("remove_btn", onClickRemove, this);
|
||||
getChild<LLUICtrl>("remove_btn")->setCommitCallback(boost::bind(LLAvatarActions::removeFriendsDialog, boost::bind(&LLScrollListCtrl::getSelectedIDs, mFriendsList)));
|
||||
//childSetAction("export_btn", onClickExport, this); Making Dummy View -HgB
|
||||
//childSetAction("import_btn", onClickImport, this); Making Dummy View -HgB
|
||||
|
||||
@@ -685,7 +670,6 @@ BOOL LLPanelFriends::refreshNamesSync(const LLAvatarTracker::buddy_map_t & all_b
|
||||
|
||||
BOOL LLPanelFriends::refreshNamesPresence(const LLAvatarTracker::buddy_map_t & all_buddies)
|
||||
{
|
||||
|
||||
std::vector<LLScrollListItem*> items = mFriendsList->getAllData();
|
||||
std::sort(items.begin(), items.end(), SortFriendsByID());
|
||||
|
||||
@@ -784,10 +768,7 @@ void LLPanelFriends::onClickProfile(void* user_data)
|
||||
const uuid_vec_t ids = panelp->mFriendsList->getSelectedIDs();
|
||||
if(!ids.empty())
|
||||
{
|
||||
LLUUID agent_id = ids[0];
|
||||
BOOL online;
|
||||
online = LLAvatarTracker::instance().isBuddyOnline(agent_id);
|
||||
LLFloaterAvatarInfo::showFromFriend(agent_id, online);
|
||||
LLAvatarActions::showProfile(ids[0]);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -843,14 +824,6 @@ void LLPanelFriends::updateColumns(void* user_data)
|
||||
}
|
||||
}
|
||||
|
||||
static void on_avatar_name_cache_start_im(const LLUUID& agent_id, const LLAvatarName& av_name)
|
||||
{
|
||||
static LLCachedControl<bool> tear_off("OtherChatsTornOff");
|
||||
if (!tear_off) gIMMgr->setFloaterOpen(true);
|
||||
gIMMgr->addSession(LLCacheName::cleanFullName(av_name.getLegacyName()), IM_NOTHING_SPECIAL, agent_id);
|
||||
make_ui_sound("UISndStartIM");
|
||||
}
|
||||
|
||||
void LLPanelFriends::onClickIM(void* user_data)
|
||||
{
|
||||
LLPanelFriends* panelp = (LLPanelFriends*)user_data;
|
||||
@@ -861,95 +834,22 @@ void LLPanelFriends::onClickIM(void* user_data)
|
||||
{
|
||||
if(ids.size() == 1)
|
||||
{
|
||||
LLAvatarNameCache::get(ids[0], boost::bind(&on_avatar_name_cache_start_im, _1, _2));
|
||||
LLAvatarActions::startIM(ids[0]);
|
||||
}
|
||||
else
|
||||
{
|
||||
static LLCachedControl<bool> tear_off("OtherChatsTornOff");
|
||||
if (!tear_off) gIMMgr->setFloaterOpen(true);
|
||||
gIMMgr->addSession("Friends Conference", IM_SESSION_CONFERENCE_START, ids[0], ids);
|
||||
make_ui_sound("UISndStartIM");
|
||||
LLAvatarActions::startConference(ids);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// static
|
||||
void LLPanelFriends::requestFriendship(const LLUUID& target_id, const std::string& target_name, const std::string& message)
|
||||
{
|
||||
LLUUID calling_card_folder_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_CALLINGCARD);
|
||||
send_improved_im(target_id,
|
||||
target_name,
|
||||
message,
|
||||
IM_ONLINE,
|
||||
IM_FRIENDSHIP_OFFERED,
|
||||
calling_card_folder_id);
|
||||
}
|
||||
|
||||
// static
|
||||
bool LLPanelFriends::callbackAddFriendWithMessage(const LLSD& notification, const LLSD& response)
|
||||
{
|
||||
S32 option = LLNotificationsUtil::getSelectedOption(notification, response);
|
||||
if (option == 0)
|
||||
{
|
||||
requestFriendship(notification["payload"]["id"].asUUID(),
|
||||
notification["payload"]["name"].asString(),
|
||||
response["message"].asString());
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
bool LLPanelFriends::callbackAddFriend(const LLSD& notification, const LLSD& response)
|
||||
{
|
||||
S32 option = LLNotification::getSelectedOption(notification, response);
|
||||
if (option == 0)
|
||||
{
|
||||
// Servers older than 1.25 require the text of the message to be the
|
||||
// calling card folder ID for the offering user. JC
|
||||
LLUUID calling_card_folder_id =
|
||||
gInventory.findCategoryUUIDForType(LLFolderType::FT_CALLINGCARD);
|
||||
std::string message = calling_card_folder_id.asString();
|
||||
requestFriendship(notification["payload"]["id"].asUUID(),
|
||||
notification["payload"]["name"].asString(),
|
||||
message);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
// static
|
||||
void LLPanelFriends::onPickAvatar( const uuid_vec_t& ids,
|
||||
const std::vector<LLAvatarName>& names )
|
||||
{
|
||||
if (names.empty()) return;
|
||||
if (ids.empty()) return;
|
||||
requestFriendshipDialog(ids[0], names[0].getCompleteName());
|
||||
}
|
||||
|
||||
// static
|
||||
void LLPanelFriends::requestFriendshipDialog(const LLUUID& id,
|
||||
const std::string& name)
|
||||
{
|
||||
if(id == gAgentID)
|
||||
{
|
||||
LLNotificationsUtil::add("AddSelfFriend");
|
||||
return;
|
||||
}
|
||||
|
||||
LLSD args;
|
||||
args["NAME"] = name;
|
||||
LLSD payload;
|
||||
payload["id"] = id;
|
||||
payload["name"] = name;
|
||||
// Look for server versions like: Second Life Server 1.24.4.95600
|
||||
if (gLastVersionChannel.find(" 1.24.") != std::string::npos)
|
||||
{
|
||||
// Old and busted server version, doesn't support friend
|
||||
// requests with messages.
|
||||
LLNotificationsUtil::add("AddFriend", args, payload, &callbackAddFriend);
|
||||
}
|
||||
else
|
||||
{
|
||||
LLNotificationsUtil::add("AddFriendWithMessage", args, payload, &callbackAddFriendWithMessage);
|
||||
}
|
||||
LLAvatarActions::requestFriendshipDialog(ids[0], names[0].getCompleteName());
|
||||
}
|
||||
|
||||
// static
|
||||
@@ -964,44 +864,6 @@ void LLPanelFriends::onClickAddFriend(void* user_data)
|
||||
}
|
||||
}
|
||||
|
||||
// static
|
||||
void LLPanelFriends::onClickRemove(void* user_data)
|
||||
{
|
||||
LLPanelFriends* panelp = (LLPanelFriends*)user_data;
|
||||
|
||||
//llinfos << "LLPanelFriends::onClickRemove()" << llendl;
|
||||
const uuid_vec_t ids = panelp->mFriendsList->getSelectedIDs();
|
||||
LLSD args;
|
||||
if(!ids.empty())
|
||||
{
|
||||
std::string msgType = "RemoveFromFriends";
|
||||
if(ids.size() == 1)
|
||||
{
|
||||
LLUUID agent_id = ids[0];
|
||||
std::string fullname;
|
||||
if (LLAvatarNameCache::getPNSName(agent_id, fullname))
|
||||
args["NAME"] = fullname;
|
||||
}
|
||||
else
|
||||
{
|
||||
msgType = "RemoveMultipleFromFriends";
|
||||
}
|
||||
LLSD payload;
|
||||
|
||||
for (uuid_vec_t::const_iterator it = ids.begin();
|
||||
it != ids.end();
|
||||
++it)
|
||||
{
|
||||
payload["ids"].append(*it);
|
||||
}
|
||||
|
||||
LLNotifications::instance().add(msgType,
|
||||
args,
|
||||
payload,
|
||||
&handleRemove);
|
||||
}
|
||||
}
|
||||
|
||||
void LLPanelFriends::onClickExport(void* user_data)
|
||||
{
|
||||
std::string agn;
|
||||
@@ -1052,7 +914,6 @@ void LLPanelFriends::onClickExport_continued(void* user_data, AIFilePicker* file
|
||||
export_file.close();
|
||||
}
|
||||
|
||||
bool LLPanelFriends::merging;
|
||||
|
||||
void LLPanelFriends::onClickImport(void* user_data)
|
||||
{
|
||||
@@ -1093,6 +954,7 @@ void LLPanelFriends::onClickImport_filepicker_continued(AIFilePicker* filepicker
|
||||
LLSD importstatellsd;
|
||||
LLSDSerialize::fromXMLDocument(importstatellsd, stateload);
|
||||
|
||||
static bool merging;
|
||||
|
||||
//LLMessageSystem* msg = gMessageSystem;
|
||||
LLSD newdata;
|
||||
@@ -1110,10 +972,10 @@ void LLPanelFriends::onClickImport_filepicker_continued(AIFilePicker* filepicker
|
||||
if(merging && importstatellsd.has(agent_id.asString()))continue;//dont need to request what we've already requested from another list import and have not got a reply yet
|
||||
|
||||
std::string agent_name = content["name"];
|
||||
if(!is_agent_friend(agent_id))//dont need to request what we have
|
||||
if(!LLAvatarActions::isFriend(agent_id))//dont need to request what we have
|
||||
{
|
||||
if(merging)importstatellsd[agent_id.asString()] = content;//MERGEEEE
|
||||
requestFriendship(agent_id, agent_name, "Imported from "+file);
|
||||
LLAvatarActions::requestFriendship(agent_id, agent_name, "Imported from "+file);
|
||||
newdata[iter->first] = iter->second;
|
||||
}else
|
||||
{
|
||||
@@ -1157,7 +1019,7 @@ void LLPanelFriends::FriendImportState(LLUUID id, bool accepted)
|
||||
if(can_map)rights |= LLRelationship::GRANT_MAP_LOCATION;
|
||||
if(can_mod)rights |= LLRelationship::GRANT_MODIFY_OBJECTS;
|
||||
if(see_online)rights |= LLRelationship::GRANT_ONLINE_STATUS;
|
||||
if(is_agent_friend(id))//is this legit shit yo
|
||||
if(LLAvatarActions::isFriend(id))//is this legit shit yo
|
||||
{
|
||||
const LLRelationship* friend_status = LLAvatarTracker::instance().getBuddyInfo(id);
|
||||
if(friend_status)
|
||||
@@ -1187,18 +1049,6 @@ void LLPanelFriends::FriendImportState(LLUUID id, bool accepted)
|
||||
}
|
||||
}
|
||||
|
||||
// static
|
||||
void LLPanelFriends::onClickOfferTeleport(void* user_data)
|
||||
{
|
||||
LLPanelFriends* panelp = (LLPanelFriends*)user_data;
|
||||
|
||||
const uuid_vec_t ids = panelp->mFriendsList->getSelectedIDs();
|
||||
if(!ids.empty())
|
||||
{
|
||||
handle_lure(ids);
|
||||
}
|
||||
}
|
||||
|
||||
// static
|
||||
void LLPanelFriends::onClickPay(void* user_data)
|
||||
{
|
||||
@@ -1207,58 +1057,52 @@ void LLPanelFriends::onClickPay(void* user_data)
|
||||
const uuid_vec_t ids = panelp->mFriendsList->getSelectedIDs();
|
||||
if(!ids.empty())
|
||||
{
|
||||
handle_pay_by_id(ids[0]);
|
||||
LLAvatarActions::pay(ids[0]);
|
||||
}
|
||||
}
|
||||
|
||||
void LLPanelFriends::confirmModifyRights(rights_map_t& ids, EGrantRevoke command)
|
||||
void LLPanelFriends::confirmModifyRights(rights_map_t& rights, EGrantRevoke command)
|
||||
{
|
||||
if (ids.empty()) return;
|
||||
if (rights.empty()) return;
|
||||
|
||||
LLSD args;
|
||||
if(!ids.empty())
|
||||
// for single friend, show their name
|
||||
if (rights.size() == 1)
|
||||
{
|
||||
rights_map_t* rights = new rights_map_t(ids);
|
||||
LLSD args;
|
||||
std::string fullname;
|
||||
if (LLAvatarNameCache::getPNSName(rights.begin()->first, fullname))
|
||||
args["NAME"] = fullname;
|
||||
|
||||
// for single friend, show their name
|
||||
if(ids.size() == 1)
|
||||
if (command == GRANT)
|
||||
{
|
||||
LLUUID agent_id = ids.begin()->first;
|
||||
std::string fullname;
|
||||
if (LLAvatarNameCache::getPNSName(agent_id, fullname))
|
||||
args["NAME"] = fullname;
|
||||
|
||||
if (command == GRANT)
|
||||
{
|
||||
LLNotificationsUtil::add("GrantModifyRights",
|
||||
args,
|
||||
LLSD(),
|
||||
boost::bind(&LLPanelFriends::modifyRightsConfirmation, this, _1, _2, rights));
|
||||
}
|
||||
else
|
||||
{
|
||||
LLNotificationsUtil::add("RevokeModifyRights",
|
||||
args,
|
||||
LLSD(),
|
||||
boost::bind(&LLPanelFriends::modifyRightsConfirmation, this, _1, _2, rights));
|
||||
}
|
||||
LLNotificationsUtil::add("GrantModifyRights",
|
||||
args,
|
||||
LLSD(),
|
||||
boost::bind(&LLPanelFriends::modifyRightsConfirmation, this, _1, _2, &rights));
|
||||
}
|
||||
else
|
||||
{
|
||||
if (command == GRANT)
|
||||
{
|
||||
LLNotificationsUtil::add("GrantModifyRightsMultiple",
|
||||
args,
|
||||
LLSD(),
|
||||
boost::bind(&LLPanelFriends::modifyRightsConfirmation, this, _1, _2, rights));
|
||||
}
|
||||
else
|
||||
{
|
||||
LLNotificationsUtil::add("RevokeModifyRightsMultiple",
|
||||
args,
|
||||
LLSD(),
|
||||
boost::bind(&LLPanelFriends::modifyRightsConfirmation, this, _1, _2, rights));
|
||||
}
|
||||
LLNotificationsUtil::add("RevokeModifyRights",
|
||||
args,
|
||||
LLSD(),
|
||||
boost::bind(&LLPanelFriends::modifyRightsConfirmation, this, _1, _2, &rights));
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (command == GRANT)
|
||||
{
|
||||
LLNotificationsUtil::add("GrantModifyRightsMultiple",
|
||||
LLSD(),
|
||||
LLSD(),
|
||||
boost::bind(&LLPanelFriends::modifyRightsConfirmation, this, _1, _2, &rights));
|
||||
}
|
||||
else
|
||||
{
|
||||
LLNotificationsUtil::add("RevokeModifyRightsMultiple",
|
||||
LLSD(),
|
||||
LLSD(),
|
||||
boost::bind(&LLPanelFriends::modifyRightsConfirmation, this, _1, _2, &rights));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1405,42 +1249,3 @@ void LLPanelFriends::sendRightsGrant(rights_map_t& ids)
|
||||
mNumRightsChanged = ids.size();
|
||||
gAgent.sendReliableMessage();
|
||||
}
|
||||
|
||||
|
||||
|
||||
// static
|
||||
bool LLPanelFriends::handleRemove(const LLSD& notification, const LLSD& response)
|
||||
{
|
||||
S32 option = LLNotificationsUtil::getSelectedOption(notification, response);
|
||||
|
||||
const LLSD& ids = notification["payload"]["ids"];
|
||||
for(LLSD::array_const_iterator itr = ids.beginArray(); itr != ids.endArray(); ++itr)
|
||||
{
|
||||
LLUUID id = itr->asUUID();
|
||||
const LLRelationship* ip = LLAvatarTracker::instance().getBuddyInfo(id);
|
||||
if(ip)
|
||||
{
|
||||
switch(option)
|
||||
{
|
||||
case 0: // YES
|
||||
if( ip->isRightGrantedTo(LLRelationship::GRANT_MODIFY_OBJECTS))
|
||||
{
|
||||
LLAvatarTracker::instance().empower(id, FALSE);
|
||||
LLAvatarTracker::instance().notifyObservers();
|
||||
}
|
||||
LLAvatarTracker::instance().terminateBuddy(id);
|
||||
LLAvatarTracker::instance().notifyObservers();
|
||||
gInventory.addChangedMask(LLInventoryObserver::LABEL | LLInventoryObserver::CALLING_CARD, LLUUID::null);
|
||||
gInventory.notifyObservers();
|
||||
break;
|
||||
|
||||
case 1: // NO
|
||||
default:
|
||||
llinfos << "No removal performed." << llendl;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -76,15 +76,6 @@ public:
|
||||
|
||||
virtual BOOL postBuild();
|
||||
|
||||
// Show a dialog explaining what friendship entails, then request
|
||||
// friendship. JC
|
||||
static void requestFriendshipDialog(const LLUUID& target_id,
|
||||
const std::string& target_name);
|
||||
|
||||
// Just request friendship, no dialog.
|
||||
static void requestFriendship(const LLUUID& target_id,
|
||||
const std::string& target_name, const std::string& message);
|
||||
|
||||
void populateContactGroupSelect();
|
||||
|
||||
private:
|
||||
@@ -130,8 +121,6 @@ private:
|
||||
// callback methods
|
||||
static void onSelectName(LLUICtrl* ctrl, void* user_data);
|
||||
static void onChangeContactGroup(LLUICtrl* ctrl, void* user_data);
|
||||
static bool callbackAddFriend(const LLSD& notification, const LLSD& response);
|
||||
static bool callbackAddFriendWithMessage(const LLSD& notification, const LLSD& response);
|
||||
static void onPickAvatar(const uuid_vec_t& ids, const std::vector<LLAvatarName>& names );
|
||||
void onContactFilterEdit(const std::string& search_string);
|
||||
static void onClickIM(void* user_data);
|
||||
@@ -140,7 +129,6 @@ private:
|
||||
static void updateColumns(void* user_data);
|
||||
static void onClickProfile(void* user_data);
|
||||
static void onClickAddFriend(void* user_data);
|
||||
static void onClickRemove(void* user_data);
|
||||
static void onClickExport(void* user_data);
|
||||
static void onClickExport_continued(void* user_data, AIFilePicker* filepicker);
|
||||
static void onClickImport(void* user_data);
|
||||
@@ -148,12 +136,9 @@ private:
|
||||
public:
|
||||
static void FriendImportState(LLUUID id, bool accepted);
|
||||
private:
|
||||
static void onClickOfferTeleport(void* user_data);
|
||||
static void onClickPay(void* user_data);
|
||||
|
||||
static void onClickModifyStatus(LLUICtrl* ctrl, void* user_data);
|
||||
|
||||
static bool handleRemove(const LLSD& notification, const LLSD& response);
|
||||
bool modifyRightsConfirmation(const LLSD& notification, const LLSD& response, rights_map_t* rights);
|
||||
|
||||
private:
|
||||
@@ -168,7 +153,6 @@ private:
|
||||
S32 mNumRightsChanged;
|
||||
S32 mNumOnline;
|
||||
std::string mLastContactSearch;
|
||||
static bool merging;
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -376,7 +376,6 @@ void LLPanelGroups::info()
|
||||
|
||||
void LLPanelGroups::startIM()
|
||||
{
|
||||
//llinfos << "LLPanelFriends::onClickIM()" << llendl;
|
||||
LLCtrlListInterface *group_list = childGetListInterface("group list");
|
||||
LLUUID group_id;
|
||||
|
||||
|
||||
@@ -31,7 +31,8 @@
|
||||
*/
|
||||
|
||||
#include "llviewerprecompiledheaders.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
|
||||
#include "llavataractions.h"
|
||||
#include "llfloaterinspect.h"
|
||||
#include "llfloatertools.h"
|
||||
#include "llcachename.h"
|
||||
@@ -39,7 +40,6 @@
|
||||
#include "llselectmgr.h"
|
||||
#include "lltoolcomp.h"
|
||||
#include "lltoolmgr.h"
|
||||
#include "llviewercontrol.h"
|
||||
#include "llviewerobject.h"
|
||||
#include "lluictrlfactory.h"
|
||||
|
||||
@@ -123,7 +123,7 @@ void LLFloaterInspect::onClickCreatorProfile(void* ctrl)
|
||||
LLSelectNode* node = sInstance->mObjectSelection->getFirstNode(&func);
|
||||
if(node)
|
||||
{
|
||||
LLFloaterAvatarInfo::showFromDirectory(node->mPermissions->getCreator());
|
||||
LLAvatarActions::showProfile(node->mPermissions->getCreator());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -153,10 +153,10 @@ void LLFloaterInspect::onClickOwnerProfile(void* ctrl)
|
||||
// [RLVa:KB] - Checked: 2009-07-08 (RLVa-1.0.0e)
|
||||
if (!gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES))
|
||||
{
|
||||
LLFloaterAvatarInfo::showFromDirectory(owner_id);
|
||||
LLAvatarActions::showProfile(owner_id);
|
||||
}
|
||||
// [/RLVa:KB]
|
||||
// LLFloaterAvatarInfo::showFromDirectory(owner_id);
|
||||
// LLAvatarActions::showProfile(owner_id);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -47,13 +47,13 @@
|
||||
|
||||
#include "llagent.h"
|
||||
#include "llagentaccess.h"
|
||||
#include "llavataractions.h"
|
||||
#include "llavatarconstants.h" //For new Online check - HgB
|
||||
#include "llbutton.h"
|
||||
#include "llcheckboxctrl.h"
|
||||
#include "llradiogroup.h"
|
||||
#include "llcombobox.h"
|
||||
#include "llfloaterauction.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "llfloateravatarpicker.h"
|
||||
#include "llfloatergroups.h"
|
||||
#include "llfloatergroupinfo.h"
|
||||
@@ -864,8 +864,7 @@ void LLPanelLandGeneral::onClickProfile()
|
||||
}
|
||||
else
|
||||
{
|
||||
const LLUUID& avatar_id = parcel->getOwnerID();
|
||||
LLFloaterAvatarInfo::showFromObject(avatar_id);
|
||||
LLAvatarActions::showProfile(parcel->getOwnerID());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1183,7 +1182,7 @@ void LLPanelLandObjects::onDoubleClickOwner(void *userdata)
|
||||
}
|
||||
else
|
||||
{
|
||||
LLFloaterAvatarInfo::showFromDirectory(owner_id);
|
||||
LLAvatarActions::showProfile(owner_id);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -35,10 +35,9 @@
|
||||
#include "llfloaterobjectiminfo.h"
|
||||
|
||||
#include "llagentdata.h"
|
||||
#include "llavataractions.h"
|
||||
#include "llcachename.h"
|
||||
#include "llcommandhandler.h"
|
||||
#include "llfloater.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "llfloatergroupinfo.h"
|
||||
#include "llfloatermute.h"
|
||||
#include "llmutelist.h"
|
||||
@@ -154,7 +153,7 @@ void LLFloaterObjectIMInfo::onClickOwner(void* data)
|
||||
else if ( (!gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES)) || (!RlvUtil::isNearbyAgent(self->mOwnerID)) )
|
||||
// [/RLVa:KB]
|
||||
{
|
||||
LLFloaterAvatarInfo::showFromObject(self->mOwnerID);
|
||||
LLAvatarActions::showProfile(self->mOwnerID);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -41,18 +41,19 @@
|
||||
#include "llinventorydefines.h"
|
||||
|
||||
#include "llagent.h"
|
||||
#include "llavataractions.h"
|
||||
#include "llbutton.h"
|
||||
#include "llcheckboxctrl.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "llfloatergroupinfo.h"
|
||||
#include "llinventorymodel.h"
|
||||
#include "llinventoryobserver.h"
|
||||
#include "lllineeditor.h"
|
||||
#include "llradiogroup.h"
|
||||
#include "llresmgr.h"
|
||||
#include "roles_constants.h"
|
||||
#include "llselectmgr.h"
|
||||
#include "lltextbox.h"
|
||||
#include "lluiconstants.h"
|
||||
#include "lltrans.h"
|
||||
#include "llviewerinventory.h"
|
||||
#include "llviewerobjectlist.h"
|
||||
#include "llviewerregion.h"
|
||||
@@ -593,10 +594,7 @@ void LLFloaterProperties::onClickCreator()
|
||||
{
|
||||
LLInventoryItem* item = findItem();
|
||||
if(!item) return;
|
||||
if(!item->getCreatorUUID().isNull())
|
||||
{
|
||||
LLFloaterAvatarInfo::showFromObject(item->getCreatorUUID());
|
||||
}
|
||||
LLAvatarActions::showProfile(item->getCreatorUUID());
|
||||
}
|
||||
|
||||
// static
|
||||
@@ -610,12 +608,11 @@ void LLFloaterProperties::onClickOwner()
|
||||
}
|
||||
else
|
||||
{
|
||||
// if(!item->getPermissions().getOwner().isNull())
|
||||
// [RLVa:KB] - Checked: 2009-07-08 (RLVa-1.0.0e)
|
||||
if ( (!item->getPermissions().getOwner().isNull()) && (!gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES)) )
|
||||
if (!gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES))
|
||||
// [/RLVa:KB]
|
||||
{
|
||||
LLFloaterAvatarInfo::showFromObject(item->getPermissions().getOwner());
|
||||
LLAvatarActions::showProfile(item->getPermissions().getOwner());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -970,7 +967,7 @@ void LLFloaterProperties::dirtyAll()
|
||||
/// LLMultiProperties
|
||||
///----------------------------------------------------------------------------
|
||||
|
||||
LLMultiProperties::LLMultiProperties(const LLRect &rect) : LLMultiFloater(std::string("Properties"), rect)
|
||||
LLMultiProperties::LLMultiProperties(const LLRect &rect) : LLMultiFloater(LLTrans::getString("MultiPropertiesTitle"), rect)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
@@ -38,9 +38,9 @@
|
||||
#include "llfontgl.h"
|
||||
|
||||
#include "llagent.h"
|
||||
#include "llavataractions.h"
|
||||
#include "llbutton.h"
|
||||
#include "llfloatergodtools.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "llnotificationsutil.h"
|
||||
#include "llparcel.h"
|
||||
#include "llscrolllistctrl.h"
|
||||
@@ -481,8 +481,7 @@ void LLFloaterTopObjects::onProfile(void* data)
|
||||
if (!list) return;
|
||||
LLScrollListItem* first_selected = list->getFirstSelected();
|
||||
if (!first_selected) return;
|
||||
LLUUID taskid = first_selected->getUUID();
|
||||
LLFloaterAvatarInfo::showFromDirectory(taskid);
|
||||
LLAvatarActions::showProfile(first_selected->getUUID());
|
||||
}
|
||||
|
||||
void LLFloaterTopObjects::onKickBtn(void* data)
|
||||
|
||||
@@ -320,6 +320,20 @@ void LLGiveInventory::logInventoryOffer(const LLUUID& to_agent, const LLUUID &im
|
||||
{
|
||||
gIMMgr->addSystemMessage(im_session_id, "inventory_item_offered", args);
|
||||
}
|
||||
// [RLVa:KB] - Checked: 2010-05-26 (RLVa-1.2.2a) | Modified: RLVa-1.2.0h
|
||||
else if ( (gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES)) && (RlvUtil::isNearbyAgent(to_agent)) &&
|
||||
(!RlvUIEnabler::hasOpenProfile(to_agent)) )
|
||||
{
|
||||
// Log to chat history if the user didn't drop on an IM session or a profile to avoid revealing the name of the recipient
|
||||
std::string strMsgName = "inventory_item_offered"; LLSD args; LLAvatarName avName;
|
||||
if (LLAvatarNameCache::get(to_agent, &avName))
|
||||
{
|
||||
args["NAME"] = RlvStrings::getAnonym(avName);
|
||||
strMsgName = "inventory_item_offered_rlv";
|
||||
}
|
||||
gIMMgr->addSystemMessage(LLUUID::null, strMsgName, args);
|
||||
}
|
||||
// [/RLVa:KB]
|
||||
// If this item was given by drag-and-drop on avatar while IM panel was open, log this action in the IM panel chat.
|
||||
else if (gIMMgr->isIMSessionOpen(session_id))
|
||||
{
|
||||
|
||||
@@ -347,17 +347,15 @@ void LLFloaterPay::onCacheOwnerName(const LLUUID& owner_id,
|
||||
const std::string& full_name,
|
||||
bool is_group)
|
||||
{
|
||||
if (is_group)
|
||||
if (LLView* view = findChild<LLView>("payee_group"))
|
||||
{
|
||||
childSetVisible("payee_group",true);
|
||||
childSetVisible("payee_resident",false);
|
||||
view->setVisible(is_group);
|
||||
}
|
||||
else
|
||||
if (LLView* view = findChild<LLView>("payee_resident"))
|
||||
{
|
||||
childSetVisible("payee_group",false);
|
||||
childSetVisible("payee_resident",true);
|
||||
view->setVisible(!is_group);
|
||||
}
|
||||
|
||||
|
||||
childSetTextArg("payee_name", "[NAME]", full_name);
|
||||
}
|
||||
|
||||
|
||||
@@ -45,13 +45,12 @@
|
||||
#include "llnotificationsutil.h"
|
||||
|
||||
#include "llagent.h"
|
||||
#include "llavataractions.h"
|
||||
#include "llbutton.h"
|
||||
#include "llcallingcard.h"
|
||||
#include "llchat.h"
|
||||
#include "llconsole.h"
|
||||
#include "llfloater.h"
|
||||
#include "llfloateractivespeakers.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "llfloaterchat.h"
|
||||
#include "llfloatergroupinfo.h"
|
||||
#include "llimview.h"
|
||||
@@ -1358,11 +1357,11 @@ BOOL LLFloaterIMPanel::postBuild()
|
||||
|
||||
if (LLButton* btn = findChild<LLButton>("profile_callee_btn"))
|
||||
{
|
||||
btn->setCommitCallback(boost::bind(&LLFloaterIMPanel::onClickProfile, this));
|
||||
btn->setCommitCallback(boost::bind(LLAvatarActions::showProfile, mOtherParticipantUUID));
|
||||
if (!mProfileButtonEnabled) btn->setEnabled(false);
|
||||
}
|
||||
if (LLButton* btn = findChild<LLButton>("profile_tele_btn"))
|
||||
btn->setCommitCallback(boost::bind(&LLFloaterIMPanel::onClickTeleport, this));
|
||||
btn->setCommitCallback(boost::bind(static_cast<void(*)(const LLUUID&)>(LLAvatarActions::offerTeleport), mOtherParticipantUUID));
|
||||
if (LLButton* btn = findChild<LLButton>("group_info_btn"))
|
||||
btn->setCommitCallback(boost::bind(&LLFloaterIMPanel::onClickGroupInfo, this));
|
||||
childSetAction("history_btn", onClickHistory, this);
|
||||
@@ -1876,25 +1875,6 @@ void LLFloaterIMPanel::onTabClick(void* userdata)
|
||||
}
|
||||
|
||||
|
||||
void LLFloaterIMPanel::onClickProfile()
|
||||
{
|
||||
// Bring up the Profile window
|
||||
if (mOtherParticipantUUID.notNull())
|
||||
{
|
||||
LLFloaterAvatarInfo::showFromDirectory(mOtherParticipantUUID);
|
||||
}
|
||||
}
|
||||
|
||||
void LLFloaterIMPanel::onClickTeleport()
|
||||
{
|
||||
if (mOtherParticipantUUID.notNull())
|
||||
{
|
||||
handle_lure(mOtherParticipantUUID);
|
||||
//do a teleport to other part id
|
||||
//LLFloaterAvatarInfo::showFromDirectory(mOtherParticipantID);
|
||||
}
|
||||
}
|
||||
|
||||
void LLFloaterIMPanel::onRPMode(const LLSD& value)
|
||||
{
|
||||
mRPMode = value.asBoolean();
|
||||
|
||||
@@ -239,10 +239,8 @@ public:
|
||||
void onInputEditorKeystroke(LLLineEditor* caller);
|
||||
static void onTabClick( void* userdata );
|
||||
|
||||
void onClickProfile();
|
||||
static void onClickHistory( void* userdata );
|
||||
void onRPMode(const LLSD& value);
|
||||
void onClickTeleport();
|
||||
void onClickGroupInfo();
|
||||
static void onClickClose( void* userdata );
|
||||
static void onClickStartCall( void* userdata );
|
||||
|
||||
@@ -36,7 +36,6 @@
|
||||
|
||||
#include "llfontgl.h"
|
||||
#include "llrect.h"
|
||||
#include "llerror.h"
|
||||
#include "llbutton.h"
|
||||
#include "llhttpclient.h"
|
||||
#include "llsdutil_math.h"
|
||||
@@ -46,6 +45,7 @@
|
||||
|
||||
#include "llagent.h"
|
||||
#include "llagentcamera.h"
|
||||
#include "llavataractions.h"
|
||||
#include "llcallingcard.h"
|
||||
#include "llchat.h"
|
||||
#include "llresmgr.h"
|
||||
@@ -53,25 +53,16 @@
|
||||
#include "llfloaterchatterbox.h"
|
||||
#include "llhttpnode.h"
|
||||
#include "llimpanel.h"
|
||||
#include "llresizebar.h"
|
||||
#include "llsdserialize.h"
|
||||
#include "lltabcontainer.h"
|
||||
#include "llviewercontrol.h"
|
||||
#include "llfloater.h"
|
||||
#include "llmutelist.h"
|
||||
#include "llresizehandle.h"
|
||||
#include "llkeyboard.h"
|
||||
#include "llui.h"
|
||||
#include "llviewermenu.h"
|
||||
#include "llcallingcard.h"
|
||||
#include "lltoolbar.h"
|
||||
#include "llviewermessage.h"
|
||||
#include "llviewerwindow.h"
|
||||
#include "llnotify.h"
|
||||
#include "llviewerregion.h"
|
||||
|
||||
#include "llfirstuse.h"
|
||||
|
||||
// [RLVa:KB]
|
||||
#include "rlvhandler.h"
|
||||
// [/RLVa:KB]
|
||||
@@ -402,7 +393,7 @@ bool inviteUserResponse(const LLSD& notification, const LLSD& response)
|
||||
EInstantMessage LLIMMgr::defaultIMTypeForAgent(const LLUUID& agent_id)
|
||||
{
|
||||
EInstantMessage type = IM_NOTHING_SPECIAL;
|
||||
if(is_agent_friend(agent_id))
|
||||
if (LLAvatarActions::isFriend(agent_id))
|
||||
{
|
||||
if(LLAvatarTracker::instance().isBuddyOnline(agent_id))
|
||||
{
|
||||
|
||||
@@ -39,9 +39,9 @@
|
||||
#include "llagentwearables.h"
|
||||
#include "llappearancemgr.h"
|
||||
#include "llattachmentsmgr.h"
|
||||
#include "llavataractions.h"
|
||||
#include "llcallingcard.h"
|
||||
#include "llfirstuse.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "llfloaterchat.h"
|
||||
#include "llfloatercustomize.h"
|
||||
#include "llfloateropenobject.h"
|
||||
@@ -4730,7 +4730,7 @@ void LLCallingCardBridge::buildContextMenu(LLMenuGL& menu, U32 flags)
|
||||
|
||||
LLInventoryItem* item = getItem();
|
||||
BOOL good_card = (item
|
||||
&& (LLUUID::null != item->getCreatorUUID())
|
||||
&& (item->getCreatorUUID().notNull())
|
||||
&& (item->getCreatorUUID() != gAgent.getID()));
|
||||
BOOL user_online = FALSE;
|
||||
if (item)
|
||||
@@ -6441,10 +6441,9 @@ public:
|
||||
virtual void doIt()
|
||||
{
|
||||
LLViewerInventoryItem* item = getItem();
|
||||
if (item && item->getCreatorUUID().notNull())
|
||||
if (item)
|
||||
{
|
||||
bool online = LLAvatarTracker::instance().isBuddyOnline(item->getCreatorUUID());
|
||||
LLFloaterAvatarInfo::showFromFriend(item->getCreatorUUID(), online);
|
||||
LLAvatarActions::showProfile(item->getCreatorUUID());
|
||||
}
|
||||
LLInvFVBridgeAction::doIt();
|
||||
}
|
||||
|
||||
@@ -78,12 +78,6 @@ void handle_track_avatar(const LLUUID& agent_id, const std::string& name)
|
||||
LLFloaterWorldMap::show(true);
|
||||
}
|
||||
|
||||
void handle_pay_by_id(const LLUUID& agent_id)
|
||||
{
|
||||
const BOOL is_group = FALSE;
|
||||
LLFloaterPay::payDirectly(&give_money, agent_id, is_group);
|
||||
}
|
||||
|
||||
void handle_mouselook(void*)
|
||||
{
|
||||
gAgentCamera.changeCameraToMouselook();
|
||||
|
||||
@@ -36,7 +36,6 @@
|
||||
class LLUUID;
|
||||
|
||||
void handle_track_avatar(const LLUUID& agent_id, const std::string& name);
|
||||
void handle_pay_by_id(const LLUUID& agent_id);
|
||||
void handle_mouselook(void*);
|
||||
void handle_map(void*);
|
||||
void handle_mini_map(void*);
|
||||
|
||||
@@ -35,8 +35,6 @@
|
||||
|
||||
#include "llnetmap.h"
|
||||
|
||||
#include "indra_constants.h"
|
||||
#include "llui.h"
|
||||
#include "llmath.h" // clampf()
|
||||
#include "llfocusmgr.h"
|
||||
#include "lllocalcliprect.h"
|
||||
@@ -46,11 +44,10 @@
|
||||
|
||||
#include "llagent.h"
|
||||
#include "llagentcamera.h"
|
||||
#include "llavataractions.h"
|
||||
#include "llavatarnamecache.h"
|
||||
#include "llcallingcard.h"
|
||||
#include "llcolorscheme.h"
|
||||
#include "llviewercontrol.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "llfloaterworldmap.h"
|
||||
#include "llframetimer.h"
|
||||
#include "lltracker.h"
|
||||
@@ -58,7 +55,6 @@
|
||||
#include "llsurface.h"
|
||||
#include "lltextbox.h"
|
||||
#include "lluictrlfactory.h"
|
||||
#include "lluuid.h"
|
||||
#include "llviewercamera.h"
|
||||
#include "llviewertexturelist.h"
|
||||
#include "llviewermenu.h"
|
||||
@@ -432,7 +428,7 @@ void LLNetMap::draw()
|
||||
avColor = em_color;
|
||||
}
|
||||
//without these dots, SL would suck.
|
||||
else if(is_agent_friend(id))
|
||||
else if(LLAvatarActions::isFriend(id))
|
||||
{
|
||||
avColor = friend_color;
|
||||
}
|
||||
@@ -1150,10 +1146,10 @@ bool LLNetMap::LLShowAgentProfile::handleEvent(LLPointer<LLEvent> event, const L
|
||||
// [RLVa:KB] - Version: 1.23.4 | Checked: 2009-07-08 (RLVa-1.0.0e) | Modified: RLVa-0.2.0b
|
||||
if (!gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES))
|
||||
{
|
||||
LLFloaterAvatarInfo::show(self->mClosestAgentAtLastRightClick);
|
||||
LLAvatarActions::showProfile(self->mClosestAgentAtLastRightClick);
|
||||
}
|
||||
// [/RLVa:KB]
|
||||
//LLFloaterAvatarInfo::show(self->mClosestAgentAtLastRightClick);
|
||||
//LLAvatarActions::showProfile(self->mClosestAgentAtLastRightClick);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -34,74 +34,47 @@
|
||||
|
||||
#include "llpanelavatar.h"
|
||||
|
||||
#include "llclassifiedflags.h"
|
||||
#include "llfontgl.h"
|
||||
#include "llcachename.h"
|
||||
|
||||
#include "llavatarconstants.h"
|
||||
#include "lluiconstants.h"
|
||||
#include "lltextbox.h"
|
||||
#include "llviewertexteditor.h"
|
||||
#include "lltexturectrl.h"
|
||||
#include "llagent.h"
|
||||
#include "llviewerwindow.h"
|
||||
#include "llavatarnamecache.h"
|
||||
#include "llbutton.h"
|
||||
#include "llcallingcard.h"
|
||||
#include "llcheckboxctrl.h"
|
||||
#include "llfloater.h"
|
||||
#include "llclassifiedflags.h"
|
||||
#include "lltextbox.h"
|
||||
#include "lltexteditor.h"
|
||||
#include "lltexturectrl.h"
|
||||
#include "llwindow.h"
|
||||
|
||||
#include "llfloaterfriends.h"
|
||||
#include "llagent.h"
|
||||
#include "llavataractions.h"
|
||||
#include "llcallingcard.h"
|
||||
#include "lldroptarget.h"
|
||||
#include "llfloatergroupinfo.h"
|
||||
#include "llfloatergroups.h"
|
||||
#include "llfloaterinventory.h"
|
||||
#include "llfloaterworldmap.h"
|
||||
#include "llfloatermute.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "lliconctrl.h"
|
||||
#include "lllineeditor.h"
|
||||
#include "llnameeditor.h"
|
||||
#include "llmutelist.h"
|
||||
#include "llnotificationsutil.h"
|
||||
#include "llpanelclassified.h"
|
||||
#include "llpanelpick.h"
|
||||
#include "llpreviewtexture.h"
|
||||
#include "llpluginclassmedia.h"
|
||||
#include "llscrolllistctrl.h"
|
||||
#include "llstatusbar.h"
|
||||
#include "lltabcontainer.h"
|
||||
#include "llimview.h"
|
||||
#include "llvoavatar.h"
|
||||
#include "llviewercontrol.h"
|
||||
#include "llviewergenericmessage.h" // send_generic_message
|
||||
#include "llviewerobjectlist.h"
|
||||
#include "llviewerregion.h"
|
||||
#include "llweb.h"
|
||||
#include "llinventorymodel.h"
|
||||
#include "roles_constants.h"
|
||||
#include "lluictrlfactory.h"
|
||||
#include "llavatarnamecache.h"
|
||||
#include "lldroptarget.h"
|
||||
|
||||
#include "llviewerwindow.h"
|
||||
#include "llweb.h"
|
||||
|
||||
#include <iosfwd>
|
||||
#include <boost/date_time.hpp>
|
||||
|
||||
|
||||
|
||||
// [RLVa:KB]
|
||||
#include "rlvhandler.h"
|
||||
// [/RLVa:KB]
|
||||
|
||||
#include "llavatarname.h"
|
||||
|
||||
// Statics
|
||||
std::list<LLPanelAvatar*> LLPanelAvatar::sAllPanels;
|
||||
BOOL LLPanelAvatar::sAllowFirstLife = FALSE;
|
||||
|
||||
extern void callback_invite_to_group(LLUUID group_id, void *user_data);
|
||||
extern void handle_lure(const LLUUID& invitee);
|
||||
extern void handle_pay_by_id(const LLUUID& payee);
|
||||
BOOL is_agent_friend(const LLUUID& agent_id);
|
||||
BOOL is_agent_mappable(const LLUUID& agent_id);
|
||||
|
||||
|
||||
@@ -197,12 +170,6 @@ void LLPanelAvatarSecondLife::clearControls()
|
||||
{
|
||||
group_list->deleteAllItems();
|
||||
}
|
||||
/*LLScrollListCtrl* ratings_list = getChild<LLScrollListCtrl>("ratings"); createDummyWidget Making Dummy -HgB
|
||||
if(ratings_list)
|
||||
{
|
||||
ratings_list->deleteAllItems();
|
||||
}*/
|
||||
|
||||
}
|
||||
|
||||
// virtual
|
||||
@@ -421,7 +388,7 @@ void LLPanelAvatarFirstLife::processProperties(void* data, EAvatarProcessorType
|
||||
void LLPanelAvatarSecondLife::onClickImage(void* data)
|
||||
{
|
||||
LLPanelAvatarSecondLife* self = (LLPanelAvatarSecondLife*)data;
|
||||
LLNameEditor* name_ctrl = self->getChild<LLNameEditor>("name");
|
||||
LLNameEditor* name_ctrl = self->getChild<LLNameEditor>("dnname");
|
||||
if(name_ctrl)
|
||||
{
|
||||
std::string name_text = name_ctrl->getText();
|
||||
@@ -506,11 +473,7 @@ bool LLPanelAvatarSecondLife::onClickPartnerHelpLoadURL(const LLSD& notification
|
||||
void LLPanelAvatarSecondLife::onClickPartnerInfo(void *data)
|
||||
{
|
||||
LLPanelAvatarSecondLife* self = (LLPanelAvatarSecondLife*) data;
|
||||
if (self->mPartnerID.notNull())
|
||||
{
|
||||
LLFloaterAvatarInfo::showFromProfile(self->mPartnerID,
|
||||
self->calcScreenRect());
|
||||
}
|
||||
LLAvatarActions::showProfile(self->mPartnerID);
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
@@ -542,8 +505,8 @@ BOOL LLPanelAvatarSecondLife::postBuild(void)
|
||||
childSetEnabled("partner_info", mPartnerID.notNull());
|
||||
|
||||
childSetAction("?",onClickPublishHelp,this);
|
||||
BOOL own_avatar = (getPanelAvatar()->getAvatarID() == gAgent.getID() );
|
||||
enableControls(own_avatar);
|
||||
LLPanelAvatar* pa = getPanelAvatar();
|
||||
enableControls(pa->getAvatarID() == gAgentID);
|
||||
|
||||
childSetVisible("About:",LLPanelAvatar::sAllowFirstLife);
|
||||
childSetVisible("(500 chars)",LLPanelAvatar::sAllowFirstLife);
|
||||
@@ -554,16 +517,15 @@ BOOL LLPanelAvatarSecondLife::postBuild(void)
|
||||
|
||||
childSetVisible("online_yes",FALSE);
|
||||
|
||||
childSetAction("Find on Map", LLPanelAvatar::onClickTrack, getPanelAvatar());
|
||||
childSetAction("Instant Message...", LLPanelAvatar::onClickIM, getPanelAvatar());
|
||||
childSetAction("GroupInvite_Button", LLPanelAvatar::onClickGroupInvite, getPanelAvatar());
|
||||
getChild<LLUICtrl>("Find on Map")->setCommitCallback(boost::bind(LLAvatarActions::showOnMap, boost::bind(&LLPanelAvatar::getAvatarID, pa)));
|
||||
getChild<LLUICtrl>("Instant Message...")->setCommitCallback(boost::bind(LLAvatarActions::startIM, boost::bind(&LLPanelAvatar::getAvatarID, pa)));
|
||||
getChild<LLUICtrl>("GroupInvite_Button")->setCommitCallback(boost::bind(LLAvatarActions::inviteToGroup, boost::bind(&LLPanelAvatar::getAvatarID, pa)));
|
||||
|
||||
childSetAction("Add Friend...", LLPanelAvatar::onClickAddFriend, getPanelAvatar());
|
||||
childSetAction("Pay...", LLPanelAvatar::onClickPay, getPanelAvatar());
|
||||
childSetAction("Mute", LLPanelAvatar::onClickMute, getPanelAvatar() );
|
||||
getChild<LLUICtrl>("Add Friend...")->setCommitCallback(boost::bind(LLAvatarActions::requestFriendshipDialog, boost::bind(&LLPanelAvatar::getAvatarID, pa)));
|
||||
getChild<LLUICtrl>("Pay...")->setCommitCallback(boost::bind(LLAvatarActions::pay, boost::bind(&LLPanelAvatar::getAvatarID, pa)));
|
||||
childSetAction("Mute", LLPanelAvatar::onClickMute, pa);
|
||||
|
||||
childSetAction("Offer Teleport...", LLPanelAvatar::onClickOfferTeleport,
|
||||
getPanelAvatar() );
|
||||
getChild<LLUICtrl>("Offer Teleport...")->setCommitCallback(boost::bind(static_cast<void(*)(const LLUUID&)>(LLAvatarActions::offerTeleport), boost::bind(&LLPanelAvatar::getAvatarID, pa)));
|
||||
|
||||
getChild<LLScrollListCtrl>("groups")->setDoubleClickCallback(boost::bind(&LLPanelAvatarSecondLife::onDoubleClickGroup,this));
|
||||
|
||||
@@ -600,8 +562,6 @@ BOOL LLPanelAvatarWeb::postBuild(void)
|
||||
url_edit->setKeystrokeCallback(boost::bind(&LLPanelAvatarWeb::onURLKeystroke,this,_1));
|
||||
url_edit->setCommitCallback(boost::bind(&LLPanelAvatarWeb::onCommitURL,this,_2));
|
||||
|
||||
getChild<LLLineEditor>("load")->setCommitCallback(boost::bind(&LLPanelAvatarWeb::onCommitLoad,this,_2));
|
||||
|
||||
childSetAction("web_profile_help",onClickWebProfileHelp,this);
|
||||
|
||||
childSetControlName("auto_load","AutoLoadWebProfiles");
|
||||
@@ -621,7 +581,7 @@ void LLPanelAvatarWeb::processProperties(void* data, EAvatarProcessorType type)
|
||||
if(type == APT_PROPERTIES)
|
||||
{
|
||||
const LLAvatarData* pAvatarData = static_cast<const LLAvatarData*>( data );
|
||||
if (pAvatarData && (mAvatarID == pAvatarData->avatar_id) && (pAvatarData->avatar_id != LLUUID::null))
|
||||
if (pAvatarData && (mAvatarID == pAvatarData->avatar_id) && (pAvatarData->avatar_id.notNull()))
|
||||
{
|
||||
setWebURL(pAvatarData->profile_url);
|
||||
}
|
||||
@@ -1424,14 +1384,13 @@ LLPanelAvatar::LLPanelAvatar(
|
||||
mPanelNotes(NULL),
|
||||
mPanelFirstLife(NULL),
|
||||
mPanelWeb(NULL),
|
||||
mAvatarID( LLUUID::null ), // mAvatarID is set with 'setAvatar' or 'setAvatarID'
|
||||
mAvatarID(LLUUID::null), // mAvatarID is set with setAvatarID()
|
||||
mHaveProperties(FALSE),
|
||||
mHaveStatistics(FALSE),
|
||||
mHaveNotes(false),
|
||||
mLastNotes(),
|
||||
mAllowEdit(allow_edit)
|
||||
{
|
||||
|
||||
sAllPanels.push_back(this);
|
||||
|
||||
LLCallbackMap::map_t factory_map;
|
||||
@@ -1447,22 +1406,19 @@ LLPanelAvatar::LLPanelAvatar(
|
||||
LLUICtrlFactory::getInstance()->buildPanel(this, "panel_avatar.xml", &factory_map);
|
||||
|
||||
selectTab(0);
|
||||
|
||||
|
||||
}
|
||||
|
||||
BOOL LLPanelAvatar::postBuild(void)
|
||||
{
|
||||
mTab = getChild<LLTabContainer>("tab");
|
||||
childSetAction("Kick",onClickKick,this);
|
||||
childSetAction("Freeze",onClickFreeze, this);
|
||||
childSetAction("Unfreeze", onClickUnfreeze, this);
|
||||
childSetAction("csr_btn", onClickCSR, this);
|
||||
getChild<LLUICtrl>("Kick")->setCommitCallback(boost::bind(LLAvatarActions::kick, boost::bind(&LLPanelAvatar::getAvatarID, this)));
|
||||
getChild<LLUICtrl>("Freeze")->setCommitCallback(boost::bind(LLAvatarActions::freeze, boost::bind(&LLPanelAvatar::getAvatarID, this)));
|
||||
getChild<LLUICtrl>("Unfreeze")->setCommitCallback(boost::bind(LLAvatarActions::unfreeze, boost::bind(&LLPanelAvatar::getAvatarID, this)));
|
||||
getChild<LLUICtrl>("csr_btn")->setCommitCallback(boost::bind(LLAvatarActions::csr, boost::bind(&LLPanelAvatar::getAvatarID, this)));
|
||||
childSetAction("OK", onClickOK, this);
|
||||
childSetAction("Cancel", onClickCancel, this);
|
||||
|
||||
childSetAction("copy_key",onClickGetKey,this);
|
||||
childSetCommitCallback("avatar_key",onCommitKey,this);
|
||||
|
||||
if(mTab && !sAllowFirstLife)
|
||||
{
|
||||
@@ -1502,38 +1458,6 @@ BOOL LLPanelAvatar::canClose()
|
||||
return !mPanelClassified || mPanelClassified->canClose();
|
||||
}
|
||||
|
||||
void LLPanelAvatar::setAvatar(LLViewerObject *avatarp)
|
||||
{
|
||||
// find the avatar and grab the name
|
||||
LLNameValue *firstname = avatarp->getNVPair("FirstName");
|
||||
LLNameValue *lastname = avatarp->getNVPair("LastName");
|
||||
|
||||
std::string name;
|
||||
if (firstname && lastname)
|
||||
{
|
||||
name.assign( firstname->getString() );
|
||||
name.append(" ");
|
||||
name.append( lastname->getString() );
|
||||
}
|
||||
else
|
||||
{
|
||||
name.assign("");
|
||||
}
|
||||
|
||||
// If we have an avatar pointer, they must be online.
|
||||
setAvatarID(avatarp->getID(), name, ONLINE_STATUS_YES);
|
||||
}
|
||||
|
||||
void LLPanelAvatar::onCommitKey(LLUICtrl* ctrl, void* data)
|
||||
{
|
||||
LLPanelAvatar* self = (LLPanelAvatar*) data;
|
||||
std::string keystring = self->getChild<LLLineEditor>("avater_key")->getText();
|
||||
LLUUID av_key = LLUUID::null;
|
||||
if(LLUUID::validate(keystring)) av_key = (LLUUID)keystring;
|
||||
|
||||
self->setAvatarID(av_key, LLStringUtil::null, ONLINE_STATUS_NO);
|
||||
}
|
||||
|
||||
void LLPanelAvatar::setOnlineStatus(EOnlineStatus online_status)
|
||||
{
|
||||
// Online status NO could be because they are hidden
|
||||
@@ -1554,6 +1478,7 @@ void LLPanelAvatar::setOnlineStatus(EOnlineStatus online_status)
|
||||
if (mAvatarID != gAgent.getID())
|
||||
{
|
||||
childSetVisible("Offer Teleport...",TRUE);
|
||||
childSetVisible("Find on Map", true);
|
||||
}
|
||||
|
||||
BOOL in_prelude = gAgent.inPrelude();
|
||||
@@ -1572,15 +1497,31 @@ void LLPanelAvatar::setOnlineStatus(EOnlineStatus online_status)
|
||||
childSetEnabled("Offer Teleport...", TRUE /*(online_status == ONLINE_STATUS_YES)*/);
|
||||
childSetToolTip("Offer Teleport...", getString("TeleportNormal"));
|
||||
}
|
||||
|
||||
// Note: we don't always know online status, so always allow gods to try to track
|
||||
childSetEnabled("Find on Map", gAgent.isGodlike() || is_agent_mappable(mAvatarID));
|
||||
if (!mIsFriend)
|
||||
{
|
||||
childSetToolTip("Find on Map", getString("ShowOnMapNonFriend"));
|
||||
}
|
||||
else if (ONLINE_STATUS_YES != online_status)
|
||||
{
|
||||
childSetToolTip("Find on Map", getString("ShowOnMapFriendOffline"));
|
||||
}
|
||||
else
|
||||
{
|
||||
childSetToolTip("Find on Map", getString("ShowOnMapFriendOnline"));
|
||||
}
|
||||
}
|
||||
|
||||
void LLPanelAvatar::onAvatarNameResponse(const LLUUID& agent_id, const LLAvatarName& av_name){
|
||||
LLLineEditor* dnname_edit = getChild<LLLineEditor>("dnname");
|
||||
if(LLAvatarNameCache::useDisplayNames() && agent_id==mAvatarID) dnname_edit->setText(av_name.getCompleteName());
|
||||
void LLPanelAvatar::onAvatarNameResponse(const LLUUID& agent_id, const LLAvatarName& av_name)
|
||||
{
|
||||
std::string name;
|
||||
LLAvatarNameCache::getPNSName(av_name, name);
|
||||
getChild<LLLineEditor>("dnname")->setText(name);
|
||||
}
|
||||
|
||||
void LLPanelAvatar::setAvatarID(const LLUUID &avatar_id, const std::string &name,
|
||||
EOnlineStatus online_status)
|
||||
void LLPanelAvatar::setAvatarID(const LLUUID &avatar_id)
|
||||
{
|
||||
if (avatar_id.isNull()) return;
|
||||
|
||||
@@ -1598,13 +1539,12 @@ void LLPanelAvatar::setAvatarID(const LLUUID &avatar_id, const std::string &name
|
||||
LLAvatarPropertiesProcessor::getInstance()->addObserver(mAvatarID, this);
|
||||
|
||||
// Determine if we have their calling card.
|
||||
mIsFriend = is_agent_friend(mAvatarID);
|
||||
mIsFriend = LLAvatarActions::isFriend(mAvatarID);
|
||||
|
||||
// setOnlineStatus uses mIsFriend
|
||||
setOnlineStatus(online_status);
|
||||
|
||||
setOnlineStatus(ONLINE_STATUS_NO);
|
||||
|
||||
BOOL own_avatar = (mAvatarID == gAgent.getID() );
|
||||
BOOL avatar_is_friend = LLAvatarTracker::instance().getBuddyInfo(mAvatarID) != NULL;
|
||||
|
||||
for(std::list<LLPanelAvatarTab*>::iterator it=mAvatarPanelList.begin();it!=mAvatarPanelList.end();++it)
|
||||
{
|
||||
@@ -1617,41 +1557,10 @@ void LLPanelAvatar::setAvatarID(const LLUUID &avatar_id, const std::string &name
|
||||
// Teens don't have this.
|
||||
if (mPanelFirstLife) mPanelFirstLife->enableControls(own_avatar && mAllowEdit);
|
||||
|
||||
getChild<LLDropTarget>("drop_target_rect")->setEntityID(mAvatarID);
|
||||
if (LLDropTarget* drop_target = findChild<LLDropTarget>("drop_target_rect"))
|
||||
drop_target->setEntityID(mAvatarID);
|
||||
|
||||
LLNameEditor* name_edit = getChild<LLNameEditor>("name");
|
||||
if(name_edit)
|
||||
{
|
||||
if (name.empty())
|
||||
{
|
||||
name_edit->setNameID(avatar_id, FALSE);
|
||||
}
|
||||
else
|
||||
{
|
||||
name_edit->setText(name);
|
||||
}
|
||||
}
|
||||
|
||||
LLLineEditor* dnname_edit = getChild<LLLineEditor>("dnname");
|
||||
LLAvatarName av_name;
|
||||
if(dnname_edit){
|
||||
if(LLAvatarNameCache::useDisplayNames()){
|
||||
if(LLAvatarNameCache::get(avatar_id, &av_name)){
|
||||
dnname_edit->setText(av_name.getCompleteName());
|
||||
}
|
||||
else{
|
||||
dnname_edit->setText(name_edit->getText());
|
||||
LLAvatarNameCache::get(avatar_id, boost::bind(&LLPanelAvatar::onAvatarNameResponse, this, _1, _2));
|
||||
}
|
||||
childSetVisible("dnname",TRUE);
|
||||
childSetVisible("name",FALSE);
|
||||
}
|
||||
else
|
||||
{
|
||||
childSetVisible("dnname",FALSE);
|
||||
childSetVisible("name",TRUE);
|
||||
}
|
||||
}
|
||||
LLAvatarNameCache::get(avatar_id, boost::bind(&LLPanelAvatar::onAvatarNameResponse, this, _1, _2));
|
||||
|
||||
LLNameEditor* key_edit = getChild<LLNameEditor>("avatar_key");
|
||||
if(key_edit)
|
||||
@@ -1727,25 +1636,8 @@ void LLPanelAvatar::setAvatarID(const LLUUID &avatar_id, const std::string &name
|
||||
childSetVisible("Mute",TRUE);
|
||||
childSetEnabled("Mute",FALSE);
|
||||
|
||||
|
||||
childSetVisible("Find on Map",TRUE);
|
||||
// Note: we don't always know online status, so always allow gods to try to track
|
||||
BOOL enable_track = gAgent.isGodlike() || is_agent_mappable(mAvatarID);
|
||||
childSetEnabled("Find on Map",enable_track);
|
||||
if (!mIsFriend)
|
||||
{
|
||||
childSetToolTip("Find on Map", getString("ShowOnMapNonFriend"));
|
||||
}
|
||||
else if (ONLINE_STATUS_YES != online_status)
|
||||
{
|
||||
childSetToolTip("Find on Map", getString("ShowOnMapFriendOffline"));
|
||||
}
|
||||
else
|
||||
{
|
||||
childSetToolTip("Find on Map", getString("ShowOnMapFriendOnline"));
|
||||
}
|
||||
childSetVisible("Add Friend...", true);
|
||||
childSetEnabled("Add Friend...", !avatar_is_friend);
|
||||
childSetEnabled("Add Friend...", !mIsFriend);
|
||||
childSetVisible("Pay...",TRUE);
|
||||
childSetEnabled("Pay...",FALSE);
|
||||
}
|
||||
@@ -1756,9 +1648,7 @@ void LLPanelAvatar::setAvatarID(const LLUUID &avatar_id, const std::string &name
|
||||
}
|
||||
}
|
||||
|
||||
BOOL is_god = FALSE;
|
||||
if (gAgent.isGodlike()) is_god = TRUE;
|
||||
|
||||
bool is_god = gAgent.isGodlike();
|
||||
childSetVisible("Kick", is_god);
|
||||
childSetEnabled("Kick", is_god);
|
||||
childSetVisible("Freeze", is_god);
|
||||
@@ -1832,36 +1722,6 @@ void LLPanelAvatar::resetGroupList()
|
||||
}
|
||||
}
|
||||
|
||||
// static
|
||||
//-----------------------------------------------------------------------------
|
||||
// onClickIM()
|
||||
//-----------------------------------------------------------------------------
|
||||
void LLPanelAvatar::onClickIM(void* userdata)
|
||||
{
|
||||
LLPanelAvatar* self = (LLPanelAvatar*) userdata;
|
||||
gIMMgr->setFloaterOpen(TRUE);
|
||||
|
||||
std::string name;
|
||||
LLNameEditor* nameedit = self->mPanelSecondLife->getChild<LLNameEditor>("name");
|
||||
if (nameedit) name = nameedit->getText();
|
||||
gIMMgr->addSession(name, IM_NOTHING_SPECIAL, self->mAvatarID);
|
||||
}
|
||||
|
||||
void LLPanelAvatar::onClickGroupInvite(void* userdata)
|
||||
{
|
||||
LLPanelAvatar* self = (LLPanelAvatar*) userdata;
|
||||
if (self->getAvatarID().notNull())
|
||||
{
|
||||
LLFloaterGroupPicker* widget;
|
||||
widget = LLFloaterGroupPicker::showInstance(LLSD(gAgent.getID()));
|
||||
if (widget)
|
||||
{
|
||||
widget->center();
|
||||
widget->setPowersMask(GP_MEMBER_INVITE);
|
||||
widget->setSelectCallback(callback_invite_to_group, (void *)&(self->getAvatarID()));
|
||||
}
|
||||
}
|
||||
}
|
||||
//static
|
||||
void LLPanelAvatar::onClickGetKey(void *userdata)
|
||||
{
|
||||
@@ -1873,37 +1733,6 @@ void LLPanelAvatar::onClickGetKey(void *userdata)
|
||||
gViewerWindow->mWindow->copyTextToClipboard(utf8str_to_wstring(agent_id.asString()));
|
||||
}
|
||||
|
||||
// static
|
||||
//-----------------------------------------------------------------------------
|
||||
// onClickTrack()
|
||||
//-----------------------------------------------------------------------------
|
||||
void LLPanelAvatar::onClickTrack(void* userdata)
|
||||
{
|
||||
LLPanelAvatar* self = (LLPanelAvatar*) userdata;
|
||||
|
||||
if( gFloaterWorldMap )
|
||||
{
|
||||
std::string name;
|
||||
LLNameEditor* nameedit = self->mPanelSecondLife->getChild<LLNameEditor>("name");
|
||||
if (nameedit) name = nameedit->getText();
|
||||
gFloaterWorldMap->trackAvatar(self->mAvatarID, name);
|
||||
LLFloaterWorldMap::show(true);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// static
|
||||
void LLPanelAvatar::onClickAddFriend(void* userdata)
|
||||
{
|
||||
LLPanelAvatar* self = (LLPanelAvatar*) userdata;
|
||||
LLNameEditor* name_edit = self->mPanelSecondLife->getChild<LLNameEditor>("name");
|
||||
if (name_edit)
|
||||
{
|
||||
LLPanelFriends::requestFriendshipDialog(self->getAvatarID(),
|
||||
name_edit->getText());
|
||||
}
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// onClickMute()
|
||||
//-----------------------------------------------------------------------------
|
||||
@@ -1912,43 +1741,18 @@ void LLPanelAvatar::onClickMute(void *userdata)
|
||||
LLPanelAvatar* self = (LLPanelAvatar*) userdata;
|
||||
|
||||
LLUUID agent_id = self->getAvatarID();
|
||||
LLNameEditor* name_edit = self->mPanelSecondLife->getChild<LLNameEditor>("name");
|
||||
|
||||
if (name_edit)
|
||||
|
||||
LLFloaterMute::showInstance();
|
||||
if (LLAvatarActions::isBlocked(agent_id))
|
||||
{
|
||||
std::string agent_name = name_edit->getText();
|
||||
LLFloaterMute::showInstance();
|
||||
|
||||
if (LLMuteList::getInstance()->isMuted(agent_id))
|
||||
{
|
||||
LLFloaterMute::getInstance()->selectMute(agent_id);
|
||||
}
|
||||
else
|
||||
{
|
||||
LLMute mute(agent_id, agent_name, LLMute::AGENT);
|
||||
LLMuteList::getInstance()->add(mute);
|
||||
}
|
||||
LLFloaterMute::getInstance()->selectMute(agent_id);
|
||||
}
|
||||
else
|
||||
{
|
||||
LLAvatarActions::toggleBlock(agent_id);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// static
|
||||
void LLPanelAvatar::onClickOfferTeleport(void *userdata)
|
||||
{
|
||||
LLPanelAvatar* self = (LLPanelAvatar*) userdata;
|
||||
|
||||
handle_lure(self->mAvatarID);
|
||||
}
|
||||
|
||||
|
||||
// static
|
||||
void LLPanelAvatar::onClickPay(void *userdata)
|
||||
{
|
||||
LLPanelAvatar* self = (LLPanelAvatar*) userdata;
|
||||
handle_pay_by_id(self->mAvatarID);
|
||||
}
|
||||
|
||||
|
||||
// static
|
||||
void LLPanelAvatar::onClickOK(void *userdata)
|
||||
{
|
||||
@@ -2043,7 +1847,7 @@ void LLPanelAvatar::processProperties(void* data, EAvatarProcessorType type)
|
||||
if(type == APT_PROPERTIES)
|
||||
{
|
||||
const LLAvatarData* pAvatarData = static_cast<const LLAvatarData*>( data );
|
||||
if (pAvatarData && (mAvatarID == pAvatarData->avatar_id) && (pAvatarData->avatar_id != LLUUID::null))
|
||||
if (pAvatarData && (mAvatarID == pAvatarData->avatar_id) && (pAvatarData->avatar_id.notNull()))
|
||||
{
|
||||
childSetEnabled("Instant Message...",TRUE);
|
||||
childSetEnabled("GroupInvite_Button",TRUE);
|
||||
@@ -2166,136 +1970,6 @@ void LLPanelAvatar::selectTabByName(std::string tab_name)
|
||||
}
|
||||
}
|
||||
|
||||
// static
|
||||
void LLPanelAvatar::onClickKick(void* userdata)
|
||||
{
|
||||
LLPanelAvatar* self = (LLPanelAvatar*) userdata;
|
||||
|
||||
S32 left, top;
|
||||
gFloaterView->getNewFloaterPosition(&left, &top);
|
||||
LLRect rect(left, top, left+400, top-300);
|
||||
|
||||
LLSD payload;
|
||||
payload["avatar_id"] = self->mAvatarID;
|
||||
LLNotificationsUtil::add("KickUser", LLSD(), payload, finishKick);
|
||||
}
|
||||
|
||||
//static
|
||||
bool LLPanelAvatar::finishKick(const LLSD& notification, const LLSD& response)
|
||||
{
|
||||
S32 option = LLNotification::getSelectedOption(notification, response);
|
||||
|
||||
if (option == 0)
|
||||
{
|
||||
LLUUID avatar_id = notification["payload"]["avatar_id"].asUUID();
|
||||
LLMessageSystem* msg = gMessageSystem;
|
||||
|
||||
msg->newMessageFast(_PREHASH_GodKickUser);
|
||||
msg->nextBlockFast(_PREHASH_UserInfo);
|
||||
msg->addUUIDFast(_PREHASH_GodID, gAgent.getID() );
|
||||
msg->addUUIDFast(_PREHASH_GodSessionID, gAgent.getSessionID());
|
||||
msg->addUUIDFast(_PREHASH_AgentID, avatar_id );
|
||||
msg->addU32("KickFlags", KICK_FLAGS_DEFAULT );
|
||||
msg->addStringFast(_PREHASH_Reason, response["message"].asString() );
|
||||
gAgent.sendReliableMessage();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
// static
|
||||
void LLPanelAvatar::onClickFreeze(void* userdata)
|
||||
{
|
||||
LLPanelAvatar* self = (LLPanelAvatar*) userdata;
|
||||
LLSD payload;
|
||||
payload["avatar_id"] = self->mAvatarID;
|
||||
LLNotificationsUtil::add("FreezeUser", LLSD(), payload, LLPanelAvatar::finishFreeze);
|
||||
}
|
||||
|
||||
// static
|
||||
bool LLPanelAvatar::finishFreeze(const LLSD& notification, const LLSD& response)
|
||||
{
|
||||
S32 option = LLNotification::getSelectedOption(notification, response);
|
||||
|
||||
if (option == 0)
|
||||
{
|
||||
LLUUID avatar_id = notification["payload"]["avatar_id"].asUUID();
|
||||
LLMessageSystem* msg = gMessageSystem;
|
||||
|
||||
msg->newMessageFast(_PREHASH_GodKickUser);
|
||||
msg->nextBlockFast(_PREHASH_UserInfo);
|
||||
msg->addUUIDFast(_PREHASH_GodID, gAgent.getID() );
|
||||
msg->addUUIDFast(_PREHASH_GodSessionID, gAgent.getSessionID());
|
||||
msg->addUUIDFast(_PREHASH_AgentID, avatar_id );
|
||||
msg->addU32("KickFlags", KICK_FLAGS_FREEZE );
|
||||
msg->addStringFast(_PREHASH_Reason, response["message"].asString() );
|
||||
gAgent.sendReliableMessage();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
// static
|
||||
void LLPanelAvatar::onClickUnfreeze(void* userdata)
|
||||
{
|
||||
LLPanelAvatar* self = (LLPanelAvatar*) userdata;
|
||||
LLSD payload;
|
||||
payload["avatar_id"] = self->mAvatarID;
|
||||
LLNotificationsUtil::add("UnFreezeUser", LLSD(), payload, LLPanelAvatar::finishUnfreeze);
|
||||
}
|
||||
|
||||
// static
|
||||
bool LLPanelAvatar::finishUnfreeze(const LLSD& notification, const LLSD& response)
|
||||
{
|
||||
S32 option = LLNotification::getSelectedOption(notification, response);
|
||||
std::string text = response["message"].asString();
|
||||
if (option == 0)
|
||||
{
|
||||
LLUUID avatar_id = notification["payload"]["avatar_id"].asUUID();
|
||||
LLMessageSystem* msg = gMessageSystem;
|
||||
|
||||
msg->newMessageFast(_PREHASH_GodKickUser);
|
||||
msg->nextBlockFast(_PREHASH_UserInfo);
|
||||
msg->addUUIDFast(_PREHASH_GodID, gAgent.getID() );
|
||||
msg->addUUIDFast(_PREHASH_GodSessionID, gAgent.getSessionID());
|
||||
msg->addUUIDFast(_PREHASH_AgentID, avatar_id );
|
||||
msg->addU32("KickFlags", KICK_FLAGS_UNFREEZE );
|
||||
msg->addStringFast(_PREHASH_Reason, text );
|
||||
gAgent.sendReliableMessage();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
// static
|
||||
void LLPanelAvatar::onClickCSR(void* userdata)
|
||||
{
|
||||
LLPanelAvatar* self = (LLPanelAvatar*)userdata;
|
||||
if (!self) return;
|
||||
|
||||
LLNameEditor* name_edit = self->getChild<LLNameEditor>("name");
|
||||
if (!name_edit) return;
|
||||
|
||||
std::string name = name_edit->getText();
|
||||
if (name.empty()) return;
|
||||
|
||||
std::string url = "http://csr.lindenlab.com/agent/";
|
||||
|
||||
// slow and stupid, but it's late
|
||||
S32 len = name.length();
|
||||
for (S32 i = 0; i < len; i++)
|
||||
{
|
||||
if (name[i] == ' ')
|
||||
{
|
||||
url += "%20";
|
||||
}
|
||||
else
|
||||
{
|
||||
url += name[i];
|
||||
}
|
||||
}
|
||||
|
||||
LLWeb::loadURL(url);
|
||||
}
|
||||
|
||||
|
||||
void* LLPanelAvatar::createPanelAvatarSecondLife(void* data)
|
||||
{
|
||||
LLPanelAvatar* self = (LLPanelAvatar*)data;
|
||||
|
||||
@@ -303,8 +303,7 @@ public:
|
||||
|
||||
// Fill in the avatar ID and handle some field fill-in, as well as
|
||||
// button enablement.
|
||||
// Pass one of the ONLINE_STATUS_foo constants above.
|
||||
void setAvatarID(const LLUUID &avatar_id, const std::string &name, EOnlineStatus online_status);
|
||||
void setAvatarID(const LLUUID &avatar_id);
|
||||
|
||||
void setOnlineStatus(EOnlineStatus online_status);
|
||||
|
||||
@@ -328,30 +327,14 @@ public:
|
||||
BOOL haveData() { return mHaveProperties && mHaveStatistics; }
|
||||
BOOL isEditable() const { return mAllowEdit; }
|
||||
|
||||
static void onClickTrack( void *userdata);
|
||||
static void onClickIM( void *userdata);
|
||||
static void onClickGroupInvite( void *userdata);
|
||||
static void onClickOfferTeleport( void *userdata);
|
||||
static void onClickPay( void *userdata);
|
||||
static void onClickGetKey(void *userdata);
|
||||
static void onClickAddFriend(void* userdata);
|
||||
static void onClickOK( void *userdata);
|
||||
static void onClickCancel( void *userdata);
|
||||
static void onClickKick( void *userdata);
|
||||
static void onClickFreeze( void *userdata);
|
||||
static void onClickUnfreeze(void *userdata);
|
||||
static void onClickCSR( void *userdata);
|
||||
static void onClickMute( void *userdata);
|
||||
static void onCommitKey(LLUICtrl* ctrl, void* data);
|
||||
|
||||
private:
|
||||
void enableOKIfReady();
|
||||
|
||||
static bool finishKick(const LLSD& notification, const LLSD& response);
|
||||
static bool finishFreeze(const LLSD& notification, const LLSD& response);
|
||||
static bool finishUnfreeze(const LLSD& notification, const LLSD& response);
|
||||
|
||||
static void showProfileCallback(S32 option, void *userdata);
|
||||
static void* createPanelAvatar(void* data);
|
||||
static void* createFloaterAvatarInfo(void* data);
|
||||
static void* createPanelAvatarSecondLife(void* data);
|
||||
@@ -393,8 +376,4 @@ private:
|
||||
static panel_list_t sAllPanels;
|
||||
};
|
||||
|
||||
// helper funcs
|
||||
void add_left_label(LLPanel *panel, const std::string& name, S32 y);
|
||||
|
||||
|
||||
#endif // LL_LLPANELAVATAR_H
|
||||
|
||||
@@ -46,20 +46,18 @@
|
||||
#include "message.h"
|
||||
|
||||
#include "llagent.h"
|
||||
#include "llavataractions.h"
|
||||
#include "llbutton.h"
|
||||
#include "llcheckboxctrl.h"
|
||||
#include "llclassifiedflags.h"
|
||||
#include "llclassifiedstatsresponder.h"
|
||||
#include "llcommandhandler.h" // for classified HTML detail page click tracking
|
||||
#include "llviewercontrol.h"
|
||||
#include "lllineeditor.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "llfloaterclassified.h"
|
||||
#include "lltextbox.h"
|
||||
#include "llcombobox.h"
|
||||
#include "llviewertexteditor.h"
|
||||
#include "lltexturectrl.h"
|
||||
#include "lluiconstants.h"
|
||||
#include "llurldispatcher.h" // for classified HTML detail click teleports
|
||||
#include "lluictrlfactory.h"
|
||||
#include "llviewerparcelmgr.h"
|
||||
@@ -894,7 +892,7 @@ void LLPanelClassified::onClickMap(void* data)
|
||||
void LLPanelClassified::onClickProfile(void* data)
|
||||
{
|
||||
LLPanelClassified* self = (LLPanelClassified*)data;
|
||||
LLFloaterAvatarInfo::showFromDirectory(self->mCreatorID);
|
||||
LLAvatarActions::showProfile(self->mCreatorID);
|
||||
self->sendClassifiedClickMessage("profile");
|
||||
}
|
||||
|
||||
|
||||
@@ -422,7 +422,7 @@ void LLPanelDirBrowser::showDetailPanel(S32 type, LLSD id)
|
||||
if (mFloaterDirectory && mFloaterDirectory->mPanelAvatarp)
|
||||
{
|
||||
mFloaterDirectory->mPanelAvatarp->setVisible(TRUE);
|
||||
mFloaterDirectory->mPanelAvatarp->setAvatarID(id.asUUID(), LLStringUtil::null, ONLINE_STATUS_NO);
|
||||
mFloaterDirectory->mPanelAvatarp->setAvatarID(id.asUUID());
|
||||
}
|
||||
break;
|
||||
case EVENT_CODE:
|
||||
|
||||
@@ -112,8 +112,6 @@ BOOL LLPanelDirClassified::postBuild()
|
||||
getChild<LLButton>("Browse")->setClickedCallback(boost::bind(&LLPanelDirBrowser::onClickSearchCore,this));
|
||||
setDefaultBtn( "Browse" );
|
||||
|
||||
getChild<LLButton>("Place an Ad...")->setClickedCallback(boost::bind(&LLPanelDirClassified::onClickCreateNewClassified,this));
|
||||
|
||||
getChild<LLButton>("Delete")->setClickedCallback(boost::bind(&LLPanelDirClassified::onClickDelete,this));
|
||||
childDisable("Delete");
|
||||
childHide("Delete");
|
||||
@@ -149,11 +147,6 @@ void LLPanelDirClassified::refresh()
|
||||
updateMaturityCheckbox();
|
||||
}
|
||||
|
||||
void LLPanelDirClassified::onClickCreateNewClassified()
|
||||
{
|
||||
LLFloaterAvatarInfo::showFromObject(gAgent.getID(), "Classified");
|
||||
}
|
||||
|
||||
void LLPanelDirClassified::onClickDelete()
|
||||
{
|
||||
LLUUID classified_id;
|
||||
|
||||
@@ -65,9 +65,6 @@ protected:
|
||||
void onClickSearch();
|
||||
|
||||
void onKeystrokeNameClassified(LLLineEditor* line);
|
||||
|
||||
//
|
||||
void onClickCreateNewClassified();
|
||||
|
||||
protected:
|
||||
};
|
||||
|
||||
@@ -36,8 +36,8 @@
|
||||
|
||||
#include "lluictrlfactory.h"
|
||||
#include "llagent.h"
|
||||
#include "llavataractions.h"
|
||||
#include "roles_constants.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "llfloatergroupinfo.h"
|
||||
|
||||
// UI elements
|
||||
@@ -394,7 +394,7 @@ void LLPanelGroupGeneral::openProfile(void* data)
|
||||
LLScrollListItem* selected = self->mListVisibleMembers->getFirstSelected();
|
||||
if (selected)
|
||||
{
|
||||
LLFloaterAvatarInfo::showFromDirectory( selected->getUUID() );
|
||||
LLAvatarActions::showProfile(selected->getUUID());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -34,10 +34,10 @@
|
||||
#include "llcheckboxctrl.h"
|
||||
|
||||
#include "llagent.h"
|
||||
#include "llavataractions.h"
|
||||
#include "llavatarnamecache.h"
|
||||
#include "llbutton.h"
|
||||
#include "llfiltereditor.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "llfloatergroupinvite.h"
|
||||
#include "lliconctrl.h"
|
||||
#include "lllineeditor.h"
|
||||
@@ -1202,8 +1202,7 @@ void LLPanelGroupMembersSubTab::handleMemberDoubleClick()
|
||||
LLScrollListItem* selected = mMembersList->getFirstSelected();
|
||||
if (selected)
|
||||
{
|
||||
LLUUID member_id = selected->getUUID();
|
||||
LLFloaterAvatarInfo::showFromDirectory( member_id );
|
||||
LLAvatarActions::showProfile(selected->getUUID());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -36,16 +36,14 @@
|
||||
|
||||
#include "llpanelpermissions.h"
|
||||
|
||||
#include "lluuid.h"
|
||||
#include "llpermissions.h"
|
||||
#include "llcategory.h"
|
||||
#include "llclickaction.h"
|
||||
#include "llfocusmgr.h"
|
||||
#include "llnotificationsutil.h"
|
||||
#include "llstring.h"
|
||||
#include "lltrans.h"
|
||||
#include "llwindow.h"
|
||||
|
||||
#include "llviewerwindow.h"
|
||||
#include "llwindow.h"
|
||||
#include "llresmgr.h"
|
||||
#include "lltextbox.h"
|
||||
#include "llbutton.h"
|
||||
@@ -53,20 +51,16 @@
|
||||
#include "llviewerobject.h"
|
||||
#include "llselectmgr.h"
|
||||
#include "llagent.h"
|
||||
#include "llstatusbar.h" // for getBalance()
|
||||
#include "llavataractions.h"
|
||||
#include "lllineeditor.h"
|
||||
#include "llradiogroup.h"
|
||||
#include "llcombobox.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "lluiconstants.h"
|
||||
#include "lldbstrings.h"
|
||||
#include "llfloatergroupinfo.h"
|
||||
#include "llfloatergroups.h"
|
||||
#include "llnamebox.h"
|
||||
#include "llviewercontrol.h"
|
||||
#include "lluictrlfactory.h"
|
||||
#include "roles_constants.h"
|
||||
#include "lltrans.h"
|
||||
#include "llinventoryfunctions.h"
|
||||
|
||||
#include "lfsimfeaturehandler.h"
|
||||
@@ -1007,7 +1001,7 @@ void LLPanelPermissions::onClickCreator(void *data)
|
||||
{
|
||||
LLPanelPermissions *self = (LLPanelPermissions *)data;
|
||||
|
||||
LLFloaterAvatarInfo::showFromObject(self->mCreatorID);
|
||||
LLAvatarActions::showProfile(self->mCreatorID);
|
||||
}
|
||||
|
||||
// static
|
||||
@@ -1026,18 +1020,17 @@ void LLPanelPermissions::onClickOwner(void *data)
|
||||
// [RLVa:KB] - Checked: 2009-07-08 (RLVa-1.0.0e)
|
||||
if (!gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES))
|
||||
{
|
||||
LLFloaterAvatarInfo::showFromObject(self->mOwnerID);
|
||||
LLAvatarActions::showProfile(self->mOwnerID);
|
||||
}
|
||||
// [/RLVa:KB]
|
||||
// LLFloaterAvatarInfo::showFromObject(self->mOwnerID);
|
||||
// LLAvatarActions::showProfile(self->mOwnerID);
|
||||
}
|
||||
}
|
||||
|
||||
void LLPanelPermissions::onClickLastOwner(void *data)
|
||||
{
|
||||
LLPanelPermissions *self = (LLPanelPermissions *)data;
|
||||
if(self->mLastOwnerID.notNull())
|
||||
LLFloaterAvatarInfo::showFromObject(self->mLastOwnerID);
|
||||
LLAvatarActions::showProfile(self->mLastOwnerID);
|
||||
}
|
||||
|
||||
void LLPanelPermissions::onClickGroup(void* data)
|
||||
|
||||
@@ -29,9 +29,13 @@
|
||||
|
||||
#ifdef AI_UNUSED
|
||||
#include "llagent.h"
|
||||
#endif // AI_UNUSED
|
||||
#include "llavataractions.h"
|
||||
#ifdef AI_UNUSED
|
||||
#include "llfloaterreg.h"
|
||||
#endif // AI_UNUSED
|
||||
#include "llcommandhandler.h"
|
||||
#ifdef AI_UNUSED
|
||||
#include "llnotificationsutil.h"
|
||||
#include "llpanelpicks.h"
|
||||
#include "lltabcontainer.h"
|
||||
@@ -75,12 +79,13 @@ public:
|
||||
}
|
||||
};
|
||||
LLProfileHandler gProfileHandler;
|
||||
#endif // AI_UNUSED
|
||||
|
||||
class LLAgentHandler : public LLCommandHandler
|
||||
{
|
||||
public:
|
||||
// requires trusted browser to trigger
|
||||
LLAgentHandler() : LLCommandHandler("agent", UNTRUSTED_THROTTLE) { }
|
||||
LLAgentHandler() : LLCommandHandler("agent", true/*UNTRUSTED_THROTTLE*/) { }
|
||||
|
||||
bool handle(const LLSD& params, const LLSD& query_map,
|
||||
LLMediaCtrl* web)
|
||||
@@ -99,11 +104,13 @@ public:
|
||||
return true;
|
||||
}
|
||||
|
||||
/* Singu TODO
|
||||
if (verb == "inspect")
|
||||
{
|
||||
LLFloaterReg::showInstance("inspect_avatar", LLSD().with("avatar_id", avatar_id));
|
||||
return true;
|
||||
}
|
||||
*/
|
||||
|
||||
if (verb == "im")
|
||||
{
|
||||
@@ -113,11 +120,13 @@ public:
|
||||
|
||||
if (verb == "pay")
|
||||
{
|
||||
/*
|
||||
if (!LLUI::sSettingGroups["config"]->getBOOL("EnableAvatarPay"))
|
||||
{
|
||||
LLNotificationsUtil::add("NoAvatarPay", LLSD(), LLSD(), std::string("SwitchToStandardSkinAndQuit"));
|
||||
return true;
|
||||
}
|
||||
*/
|
||||
|
||||
LLAvatarActions::pay(avatar_id);
|
||||
return true;
|
||||
@@ -159,6 +168,7 @@ public:
|
||||
LLAgentHandler gAgentHandler;
|
||||
|
||||
|
||||
#ifdef AI_UNUSED
|
||||
//-- LLPanelProfile::ChildStack begins ----------------------------------------
|
||||
LLPanelProfile::ChildStack::ChildStack()
|
||||
: mParent(NULL)
|
||||
|
||||
@@ -54,6 +54,7 @@
|
||||
#include "llagent.h"
|
||||
#include "llvoavatarself.h"
|
||||
#include "llselectmgr.h"
|
||||
#include "lltrans.h"
|
||||
#include "llviewerinventory.h"
|
||||
#include "llviewerassettype.h"
|
||||
|
||||
@@ -550,7 +551,7 @@ void LLPreview::handleReshape(const LLRect& new_rect, bool by_user)
|
||||
// LLMultiPreview
|
||||
//
|
||||
|
||||
LLMultiPreview::LLMultiPreview(const LLRect& rect) : LLMultiFloater(std::string("Preview"), rect)
|
||||
LLMultiPreview::LLMultiPreview(const LLRect& rect) : LLMultiFloater(LLTrans::getString("MultiPreviewTitle"), rect)
|
||||
{
|
||||
setCanResize(TRUE);
|
||||
}
|
||||
@@ -558,7 +559,7 @@ LLMultiPreview::LLMultiPreview(const LLRect& rect) : LLMultiFloater(std::string(
|
||||
void LLMultiPreview::open() /*Flawfinder: ignore*/
|
||||
{
|
||||
LLMultiFloater::open(); /*Flawfinder: ignore*/
|
||||
LLPreview* frontmost_preview = (LLPreview*)mTabContainer->getCurrentPanel();
|
||||
LLPreview* frontmost_preview = dynamic_cast<LLPreview*>(mTabContainer->getCurrentPanel());
|
||||
if (frontmost_preview && frontmost_preview->getAssetStatus() == LLPreview::PREVIEW_ASSET_UNLOADED)
|
||||
{
|
||||
frontmost_preview->loadAsset();
|
||||
@@ -571,7 +572,7 @@ void LLMultiPreview::handleReshape(const LLRect& new_rect, bool by_user)
|
||||
{
|
||||
if(new_rect.getWidth() != getRect().getWidth() || new_rect.getHeight() != getRect().getHeight())
|
||||
{
|
||||
LLPreview* frontmost_preview = (LLPreview*)mTabContainer->getCurrentPanel();
|
||||
LLPreview* frontmost_preview = dynamic_cast<LLPreview*>(mTabContainer->getCurrentPanel());
|
||||
if (frontmost_preview) frontmost_preview->userResized();
|
||||
}
|
||||
LLFloater::handleReshape(new_rect, by_user);
|
||||
@@ -580,7 +581,7 @@ void LLMultiPreview::handleReshape(const LLRect& new_rect, bool by_user)
|
||||
|
||||
void LLMultiPreview::tabOpen(LLFloater* opened_floater)
|
||||
{
|
||||
LLPreview* opened_preview = (LLPreview*)opened_floater;
|
||||
LLPreview* opened_preview = dynamic_cast<LLPreview*>(opened_floater);
|
||||
if (opened_preview && opened_preview->getAssetStatus() == LLPreview::PREVIEW_ASSET_UNLOADED)
|
||||
{
|
||||
opened_preview->loadAsset();
|
||||
|
||||
@@ -35,6 +35,7 @@
|
||||
#include "llpreviewtexture.h"
|
||||
|
||||
#include "llagent.h"
|
||||
#include "llavataractions.h"
|
||||
#include "llbutton.h"
|
||||
#include "llcombobox.h"
|
||||
#include "statemachine/aifilepicker.h"
|
||||
@@ -47,12 +48,10 @@
|
||||
#include "lltrans.h"
|
||||
#include "lltextbox.h"
|
||||
#include "lltextureview.h"
|
||||
#include "llui.h"
|
||||
#include "llviewertexturelist.h"
|
||||
#include "lluictrlfactory.h"
|
||||
#include "llviewerwindow.h"
|
||||
#include "lllineeditor.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
|
||||
const S32 PREVIEW_TEXTURE_MIN_WIDTH = 300;
|
||||
const S32 PREVIEW_TEXTURE_MIN_HEIGHT = 120;
|
||||
@@ -672,8 +671,7 @@ bool LLPreviewTexture::setAspectRatio(const F32 width, const F32 height)
|
||||
void LLPreviewTexture::onClickProfile(void* userdata)
|
||||
{
|
||||
LLPreviewTexture* self = (LLPreviewTexture*) userdata;
|
||||
LLUUID key = self->mCreatorKey;
|
||||
if (!key.isNull()) LLFloaterAvatarInfo::showFromDirectory(key);
|
||||
LLAvatarActions::showProfile(self->mCreatorKey);
|
||||
}
|
||||
|
||||
void LLPreviewTexture::onAspectRatioCommit(LLUICtrl* ctrl, void* userdata)
|
||||
|
||||
@@ -39,6 +39,7 @@
|
||||
#include "lldiriterator.h"
|
||||
#include "llevent.h" // LLSimpleListener
|
||||
#include "llhoverview.h"
|
||||
#include "llhttpclient.h"
|
||||
#include "llkeyboard.h"
|
||||
#include "llmimetypes.h"
|
||||
#include "llnotifications.h"
|
||||
@@ -57,7 +58,7 @@
|
||||
#include "llweb.h"
|
||||
#include "llwebprofile.h"
|
||||
|
||||
#include "llfloateravatarinfo.h" // for getProfileURL() function
|
||||
std::string getProfileURL(const std::string& agent_name);
|
||||
//#include "viewerversion.h"
|
||||
|
||||
class AIHTTPTimeoutPolicy;
|
||||
|
||||
@@ -63,7 +63,6 @@
|
||||
#include "llfirstuse.h"
|
||||
#include "llfloaterabout.h"
|
||||
#include "llfloateractivespeakers.h"
|
||||
#include "llfloateravatarinfo.h"
|
||||
#include "llfloateravatarlist.h"
|
||||
#include "llfloateravatartextures.h"
|
||||
#include "llfloaterbeacons.h"
|
||||
@@ -79,12 +78,9 @@
|
||||
#include "llfloaterdirectory.h"
|
||||
#include "llfloatereditui.h"
|
||||
#include "llfloaterchatterbox.h"
|
||||
#include "llfloaterfriends.h"
|
||||
#include "llfloaterfonttest.h"
|
||||
#include "llfloatergesture.h"
|
||||
#include "llfloatergodtools.h"
|
||||
#include "llfloatergroupinvite.h"
|
||||
#include "llfloatergroups.h"
|
||||
#include "llfloaterhtmlcurrency.h"
|
||||
#include "llfloatermediabrowser.h" // gViewerHtmlHelp
|
||||
#include "llfloaterhud.h"
|
||||
@@ -120,6 +116,7 @@
|
||||
#include "llfloatermemleak.h"
|
||||
#include "llframestats.h"
|
||||
#include "llgivemoney.h"
|
||||
#include "llavataractions.h"
|
||||
#include "llgroupmgr.h"
|
||||
#include "llhoverview.h"
|
||||
#include "llhudeffecttrail.h"
|
||||
@@ -3763,11 +3760,6 @@ bool LLHaveCallingcard::operator()(LLInventoryCategory* cat,
|
||||
}
|
||||
*/
|
||||
|
||||
BOOL is_agent_friend(const LLUUID& agent_id)
|
||||
{
|
||||
return (LLAvatarTracker::instance().getBuddyInfo(agent_id) != NULL);
|
||||
}
|
||||
|
||||
BOOL is_agent_mappable(const LLUUID& agent_id)
|
||||
{
|
||||
const LLRelationship* buddy_info = LLAvatarTracker::instance().getBuddyInfo(agent_id);
|
||||
@@ -3785,9 +3777,9 @@ class LLAvatarEnableAddFriend : public view_listener_t
|
||||
bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata)
|
||||
{
|
||||
LLVOAvatar* avatar = find_avatar_from_object(LLSelectMgr::getInstance()->getSelection()->getPrimaryObject());
|
||||
// bool new_value = avatar && !is_agent_friend(avatar->getID());
|
||||
// bool new_value = avatar && !LLAvatarActions::isFriend(avatar->getID());
|
||||
// [RLVa:KB] - Checked: 2010-04-20 (RLVa-1.2.0f) | Modified: RLVa-1.2.0f
|
||||
bool new_value = avatar && !is_agent_friend(avatar->getID()) && (!gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES));
|
||||
bool new_value = avatar && !LLAvatarActions::isFriend(avatar->getID()) && (!gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES));
|
||||
// [/RLVa:KB]
|
||||
gMenuHolder->findControl(userdata["control"].asString())->setValue(new_value);
|
||||
return true;
|
||||
@@ -3809,7 +3801,7 @@ void request_friendship(const LLUUID& dest_id)
|
||||
}
|
||||
if (!full_name.empty())
|
||||
{
|
||||
LLPanelFriends::requestFriendshipDialog(dest_id, full_name);
|
||||
LLAvatarActions::requestFriendshipDialog(dest_id, full_name);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -6089,30 +6081,6 @@ void handle_look_at_selection(const LLSD& param)
|
||||
}
|
||||
}
|
||||
|
||||
void callback_invite_to_group(LLUUID group_id, void *user_data)
|
||||
{
|
||||
std::vector<LLUUID> agent_ids;
|
||||
agent_ids.push_back(*(LLUUID *)user_data);
|
||||
|
||||
LLFloaterGroupInvite::showForGroup(group_id, &agent_ids);
|
||||
}
|
||||
|
||||
void invite_to_group(const LLUUID& dest_id)
|
||||
{
|
||||
LLViewerObject* dest = gObjectList.findObject(dest_id);
|
||||
if(dest && dest->isAvatar())
|
||||
{
|
||||
LLFloaterGroupPicker* widget;
|
||||
widget = LLFloaterGroupPicker::showInstance(LLSD(gAgent.getID()));
|
||||
if (widget)
|
||||
{
|
||||
widget->center();
|
||||
widget->setPowersMask(GP_MEMBER_INVITE);
|
||||
widget->setSelectCallback(callback_invite_to_group, (void *)&dest_id);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
class LLAvatarInviteToGroup : public view_listener_t
|
||||
{
|
||||
bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata)
|
||||
@@ -6123,7 +6091,7 @@ class LLAvatarInviteToGroup : public view_listener_t
|
||||
if ( (avatar) && (!gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES)) )
|
||||
// [/RLVa:KB]
|
||||
{
|
||||
invite_to_group(avatar->getID());
|
||||
LLAvatarActions::inviteToGroup(avatar->getID());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
@@ -6134,9 +6102,9 @@ class LLAvatarAddFriend : public view_listener_t
|
||||
bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata)
|
||||
{
|
||||
LLVOAvatar* avatar = find_avatar_from_object( LLSelectMgr::getInstance()->getSelection()->getPrimaryObject() );
|
||||
// if(avatar && !is_agent_friend(avatar->getID()))
|
||||
// if(avatar && !LLAvatarActions::isFriend(avatar->getID()))
|
||||
// [RLVa:KB] - Checked: 2010-04-20 (RLVa-1.2.0f) | Modified: RLVa-1.2.0f
|
||||
if ( (avatar && !is_agent_friend(avatar->getID())) && (!gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES)) )
|
||||
if ( (avatar && !LLAvatarActions::isFriend(avatar->getID())) && (!gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES)) )
|
||||
// [/RLVa:KB]
|
||||
{
|
||||
request_friendship(avatar->getID());
|
||||
@@ -6618,7 +6586,7 @@ class LLShowAgentProfile : public view_listener_t
|
||||
if ( (avatar) && ((!gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES)) || (gAgent.getID() == agent_id)) )
|
||||
// [/RLVa:KB]
|
||||
{
|
||||
LLFloaterAvatarInfo::show(avatar->getID());
|
||||
LLAvatarActions::showProfile(avatar->getID());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
@@ -7269,28 +7237,12 @@ class LLAvatarSendIM : public view_listener_t
|
||||
bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata)
|
||||
{
|
||||
LLVOAvatar* avatar = find_avatar_from_object( LLSelectMgr::getInstance()->getSelection()->getPrimaryObject() );
|
||||
// [RLVa:KB] - Checked: 2009-07-08 (RLVa-1.0.0e) | OK
|
||||
if (gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
// if(avatar)
|
||||
// [RLVa:KB] - Checked: 2010-06-04 (RLVa-1.2.0d) | Added: RLVa-1.2.0d
|
||||
if ((avatar) && (!gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES)))
|
||||
// [/RLVa:KB]
|
||||
if(avatar)
|
||||
{
|
||||
std::string name("IM");
|
||||
LLNameValue *first = avatar->getNVPair("FirstName");
|
||||
LLNameValue *last = avatar->getNVPair("LastName");
|
||||
if (first && last)
|
||||
{
|
||||
name.assign( first->getString() );
|
||||
name.append(" ");
|
||||
name.append( last->getString() );
|
||||
}
|
||||
|
||||
gIMMgr->setFloaterOpen(TRUE);
|
||||
//EInstantMessage type = have_agent_callingcard(gLastHitObjectID)
|
||||
// ? IM_SESSION_ADD : IM_SESSION_CARDLESS_START;
|
||||
gIMMgr->addSession(LLCacheName::cleanFullName(name),IM_NOTHING_SPECIAL,avatar->getID());
|
||||
LLAvatarActions::startIM(avatar->getID());
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -74,8 +74,6 @@ BOOL enable_deselect(void*);
|
||||
BOOL enable_undo(void*);
|
||||
BOOL enable_redo(void*);
|
||||
|
||||
// returns TRUE if we have a friend relationship with agent_id
|
||||
BOOL is_agent_friend(const LLUUID& agent_id);
|
||||
BOOL is_agent_mappable(const LLUUID& agent_id);
|
||||
|
||||
void menu_toggle_control( void* user_data );
|
||||
|
||||
@@ -2680,9 +2680,10 @@ void process_improved_im(LLMessageSystem *msg, void **user_data)
|
||||
case IM_INVENTORY_ACCEPTED:
|
||||
{
|
||||
// args["NAME"] = name;
|
||||
// [RLVa:KB] - Version: 1.23.4 | Checked: 2009-07-08 (RLVa-1.0.0e) | Modified: RLVa-0.2.0b
|
||||
// [RLVa:KB] - Checked: 2010-11-02 (RLVa-1.2.2a) | Modified: RLVa-1.2.2a
|
||||
// Only anonymize the name if the agent is nearby, there isn't an open IM session to them and their profile isn't open
|
||||
bool fRlvFilterName = (gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES)) && (RlvUtil::isNearbyAgent(from_id)) &&
|
||||
(!LLFloaterAvatarInfo::getInstance(from_id));
|
||||
(!RlvUIEnabler::hasOpenProfile(from_id)) && (!RlvUIEnabler::hasOpenIM(from_id));
|
||||
args["NAME"] = (!fRlvFilterName) ? name : RlvStrings::getAnonym(name);
|
||||
// [/RLVa:KB]
|
||||
LLNotificationsUtil::add("InventoryAccepted", args);
|
||||
@@ -2691,9 +2692,10 @@ void process_improved_im(LLMessageSystem *msg, void **user_data)
|
||||
case IM_INVENTORY_DECLINED:
|
||||
{
|
||||
// args["NAME"] = name;
|
||||
// [RLVa:KB] - Version: 1.23.4 | Checked: 2009-07-08 (RLVa-1.0.0e) | Modified: RLVa-0.2.0b
|
||||
// [RLVa:KB] - Checked: 2010-11-02 (RLVa-1.2.2a) | Modified: RLVa-1.2.2a
|
||||
// Only anonymize the name if the agent is nearby, there isn't an open IM session to them and their profile isn't open
|
||||
bool fRlvFilterName = (gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES)) && (RlvUtil::isNearbyAgent(from_id)) &&
|
||||
(!LLFloaterAvatarInfo::getInstance(from_id));
|
||||
(!RlvUIEnabler::hasOpenProfile(from_id)) && (!RlvUIEnabler::hasOpenIM(from_id));
|
||||
args["NAME"] = (!fRlvFilterName) ? name : RlvStrings::getAnonym(name);
|
||||
// [/RLVa:KB]
|
||||
LLNotificationsUtil::add("InventoryDeclined", args);
|
||||
|
||||
@@ -1238,7 +1238,7 @@ void LLWorldMapView::drawAgents()
|
||||
// Show Individual agents (or little stacks where real agents are)
|
||||
|
||||
// Here's how we'd choose the color if info.mID were available but it's not being sent:
|
||||
// LLColor4 color = (agent_count == 1 && is_agent_friend(info.mID)) ? friend_color : avatar_color;
|
||||
// LLColor4 color = (agent_count == 1 && LLAvatarActions::isFriend(info.mID)) ? friend_color : avatar_color;
|
||||
// Reduce the stack size as you zoom out - always display at lease one agent where there is one or more
|
||||
S32 agent_count = (S32)(((it->getCount()-1) * agents_scale + (it->getCount()-1) * 0.1f)+.1f) + 1;
|
||||
drawImageStack(it->getGlobalPosition(), sAvatarSmallImage, agent_count, 3.f, avatar_color);
|
||||
|
||||
@@ -151,6 +151,8 @@ enum ERlvBehaviour {
|
||||
RLV_BHVR_SENDIMTO, // "sendimto"
|
||||
RLV_BHVR_RECVIM, // "recvim"
|
||||
RLV_BHVR_RECVIMFROM, // "recvimfrom"
|
||||
RLV_BHVR_STARTIM, // "startim"
|
||||
RLV_BHVR_STARTIMTO, // "startimto"
|
||||
RLV_BHVR_PERMISSIVE, // "permissive"
|
||||
RLV_BHVR_NOTIFY, // "notify"
|
||||
RLV_BHVR_SHOWINV, // "showinv"
|
||||
|
||||
@@ -58,6 +58,7 @@ bool rlvGetShowException(ERlvBehaviour eBhvr)
|
||||
case RLV_BHVR_RECVEMOTE:
|
||||
case RLV_BHVR_SENDIM:
|
||||
case RLV_BHVR_RECVIM:
|
||||
case RLV_BHVR_STARTIM:
|
||||
case RLV_BHVR_TPLURE:
|
||||
case RLV_BHVR_ACCEPTTP:
|
||||
return true;
|
||||
|
||||
@@ -1322,6 +1322,7 @@ ERlvCmdRet RlvHandler::processAddRemCommand(const RlvCommand& rlvCmd)
|
||||
case RLV_BHVR_RECVEMOTE: // @recvemote[:<uuid>]=n|y - Checked: 2009-12-05 (RLVa-1.1.0h) | Modified: RLVa-1.1.0h
|
||||
case RLV_BHVR_SENDIM: // @sendim[:<uuid>]=n|y - Checked: 2009-12-05 (RLVa-1.1.0h) | Modified: RLVa-1.1.0h
|
||||
case RLV_BHVR_RECVIM: // @recvim[:<uuid>]=n|y - Checked: 2009-12-05 (RLVa-1.1.0h) | Modified: RLVa-1.1.0h
|
||||
case RLV_BHVR_STARTIM: // @startim[:<uuid>]=n|y - Checked: 2011-04-11 (RLVa-1.3.0h) | Added: RLVa-1.3.0h
|
||||
case RLV_BHVR_TPLURE: // @tplure[:<uuid>]=n|y - Checked: 2009-12-05 (RLVa-1.1.0h) | Modified: RLVa-1.1.0h
|
||||
case RLV_BHVR_ACCEPTTP: // @accepttp[:<uuid>]=n|y - Checked: 2009-12-05 (RLVa-1.1.0h) | Modified: RLVa-1.1.0h
|
||||
case RLV_BHVR_TOUCHATTACH: // @touchattach[:<uuid>=n|y - Checked: 2010-01-01 (RLVa-1.1.0l) | Added: RLVa-1.1.0l
|
||||
@@ -1350,6 +1351,7 @@ ERlvCmdRet RlvHandler::processAddRemCommand(const RlvCommand& rlvCmd)
|
||||
case RLV_BHVR_RECVEMOTEFROM: // @recvemotefrom:<uuid>=n|y - Checked: 2010-11-30 (RLVa-1.3.0c) | Added: RLVa-1.3.0c
|
||||
case RLV_BHVR_SENDIMTO: // @sendimto:<uuid>=n|y - Checked: 2010-11-30 (RLVa-1.3.0c) | Added: RLVa-1.3.0c
|
||||
case RLV_BHVR_RECVIMFROM: // @recvimfrom:<uuid>=n|y - Checked: 2010-11-30 (RLVa-1.3.0c) | Added: RLVa-1.3.0c
|
||||
case RLV_BHVR_STARTIMTO: // @startimto:<uuid>=n|y - Checked: 2011-04-11 (RLVa-1.3.0h) | Added: RLVa-1.3.0h
|
||||
case RLV_BHVR_EDITOBJ: // @editobj:<uuid>=n|y - Checked: 2010-11-29 (RLVa-1.3.0c) | Added: RLVa-1.3.0c
|
||||
case RLV_BHVR_TOUCHTHIS: // @touchthis:<uuid>=n|y - Checked: 2010-01-01 (RLVa-1.1.0l) | Added: RLVa-1.1.0l
|
||||
{
|
||||
|
||||
@@ -96,6 +96,7 @@ public:
|
||||
bool canShowHoverText(const LLViewerObject* pObj) const; // @showhovertext* command family
|
||||
bool canSendIM(const LLUUID& idRecipient) const; // @sendim and @sendimto
|
||||
bool canSit(LLViewerObject* pObj, const LLVector3& posOffset = LLVector3::zero) const;
|
||||
bool canStartIM(const LLUUID& idRecipient) const; // @startim and @startimto
|
||||
bool canStand() const;
|
||||
bool canTeleportViaLure(const LLUUID& idAgent) const;
|
||||
bool canTouch(const LLViewerObject* pObj, const LLVector3& posOffset = LLVector3::zero) const; // @touch
|
||||
@@ -276,6 +277,15 @@ inline bool RlvHandler::canShowHoverText(const LLViewerObject *pObj) const
|
||||
(isException(RLV_BHVR_SHOWHOVERTEXT, pObj->getID(), RLV_CHECK_PERMISSIVE)) ) );
|
||||
}
|
||||
|
||||
inline bool RlvHandler::canStartIM(const LLUUID& idRecipient) const
|
||||
{
|
||||
// User can start an IM session with "recipient" (could be an agent or a group) if:
|
||||
// - not generally restricted from starting IM sessions (or the recipient is an exception)
|
||||
// - not specifically restricted from starting an IM session with the recipient
|
||||
return
|
||||
( (!hasBehaviour(RLV_BHVR_STARTIM)) || (isException(RLV_BHVR_STARTIM, idRecipient)) ) &&
|
||||
( (!hasBehaviour(RLV_BHVR_STARTIMTO)) || (!isException(RLV_BHVR_STARTIMTO, idRecipient)) );
|
||||
}
|
||||
|
||||
// Checked: 2010-12-11 (RLVa-1.2.2c) | Added: RLVa-1.2.2c
|
||||
inline bool RlvHandler::canTeleportViaLure(const LLUUID& idAgent) const
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
#include "llviewerprecompiledheaders.h"
|
||||
#include "llagent.h"
|
||||
#include "llavataractions.h" // LLAvatarActions::profileVisible()
|
||||
#include "llavatarnamecache.h"
|
||||
#include "llenvmanager.h"
|
||||
#include "llhudtext.h" // LLHUDText::refreshAllObjectText()
|
||||
@@ -471,10 +472,10 @@ bool RlvUIEnabler::canViewRegionProperties()
|
||||
}
|
||||
|
||||
// Checked: 2010-04-20 (RLVa-1.2.0f) | Added: RLVa-1.2.0f
|
||||
/*bool RlvUIEnabler::hasOpenIM(const LLUUID& idAgent)
|
||||
bool RlvUIEnabler::hasOpenIM(const LLUUID& idAgent)
|
||||
{
|
||||
LLUUID idSession = LLIMMgr::computeSessionID(IM_NOTHING_SPECIAL, idAgent);
|
||||
return (NULL != LLFloaterReg::findInstance("impanel", idSession));
|
||||
return gIMMgr->hasSession(idSession);
|
||||
}
|
||||
|
||||
// Checked: 2011-11-04 (RLVa-1.4.4a) | Modified: RLVa-1.4.4a
|
||||
@@ -486,7 +487,7 @@ bool RlvUIEnabler::hasOpenProfile(const LLUUID& idAgent)
|
||||
|
||||
// Check if the user has the specified agent's profile open
|
||||
return LLAvatarActions::profileVisible(idAgent);
|
||||
}*/
|
||||
}
|
||||
|
||||
// Checked: 2010-09-11 (RLVa-1.2.1d) | Added: RLVa-1.2.1d
|
||||
bool RlvUIEnabler::isBuildEnabled()
|
||||
|
||||
@@ -80,8 +80,8 @@ protected:
|
||||
public:
|
||||
static bool canViewParcelProperties(); // showloc
|
||||
static bool canViewRegionProperties(); // showloc
|
||||
//static bool hasOpenIM(const LLUUID& idAgent); // shownames
|
||||
//static bool hasOpenProfile(const LLUUID& idAgent); // shownames
|
||||
static bool hasOpenIM(const LLUUID& idAgent); // shownames
|
||||
static bool hasOpenProfile(const LLUUID& idAgent); // shownames
|
||||
static bool isBuildEnabled(); // edit and rez
|
||||
|
||||
/*
|
||||
|
||||
@@ -157,9 +157,6 @@
|
||||
<button bottom="-48" follows="right|top" font="SansSerif" halign="center" height="20"
|
||||
label="Search" label_selected="Search" left="121" mouse_opaque="true" name="Search"
|
||||
visible="false" width="95" />
|
||||
<button bottom="-46" follows="right|top" font="SansSerif" halign="center" height="20"
|
||||
label="Place an Ad..." label_selected="Place an Ad..." left="630"
|
||||
mouse_opaque="true" name="Place an Ad..." width="145" />
|
||||
<button bottom="-533" follows="left|bottom" font="SansSerif" halign="center"
|
||||
height="20" label="Delete" label_selected="Delete" left="80"
|
||||
mouse_opaque="true" name="Delete" width="80" />
|
||||
|
||||
@@ -134,9 +134,6 @@
|
||||
<button bottom="-48" follows="right|top" font="SansSerif" halign="center" height="20"
|
||||
label="Search" label_selected="Search" left="121" mouse_opaque="true" name="Search"
|
||||
visible="false" width="95" />
|
||||
<button bottom="-46" follows="right|top" font="SansSerif" halign="center" height="20"
|
||||
label="Place an Ad..." label_selected="Place an Ad..." left="630"
|
||||
mouse_opaque="true" name="Place an Ad..." width="145" />
|
||||
<button bottom="-533" follows="left|bottom" font="SansSerif" halign="center"
|
||||
height="20" label="Delete" label_selected="Delete" left="80"
|
||||
mouse_opaque="true" name="Delete" width="80" />
|
||||
|
||||
@@ -216,9 +216,6 @@
|
||||
<button bottom="-48" follows="right|top" font="SansSerif" halign="center" height="20"
|
||||
label="Search" label_selected="Search" left="121" mouse_opaque="true" name="Search"
|
||||
visible="false" width="95" />
|
||||
<button bottom="-46" follows="right|top" font="SansSerif" halign="center" height="20"
|
||||
label="Place an Ad..." label_selected="Place an Ad..." left="630"
|
||||
mouse_opaque="true" name="Place an Ad..." width="145" />
|
||||
<button bottom="-533" follows="left|bottom" font="SansSerif" halign="center"
|
||||
height="20" label="Delete" label_selected="Delete" left="80"
|
||||
mouse_opaque="true" name="Delete" width="80" />
|
||||
|
||||
@@ -2352,20 +2352,6 @@ Unable to buy land for the group:
|
||||
You do not have permission to buy land for your active group.
|
||||
</notification>
|
||||
|
||||
<notification
|
||||
icon="alertmodal.tga"
|
||||
label="Add Friend"
|
||||
name="AddFriend"
|
||||
type="alertmodal">
|
||||
Friends can give permissions to track each other on the map and receive online status updates.
|
||||
|
||||
Offer friendship to [NAME]?
|
||||
<usetemplate
|
||||
name="okcancelbuttons"
|
||||
notext="Cancel"
|
||||
yestext="OK"/>
|
||||
</notification>
|
||||
|
||||
<notification
|
||||
icon="alertmodal.tga"
|
||||
label="Add Friend"
|
||||
@@ -6660,6 +6646,13 @@ An object named [OBJECTFROMNAME] owned by (an unknown user) has given you a [OBJ
|
||||
</form>
|
||||
</notification>
|
||||
|
||||
<notification
|
||||
icon="notify.tga"
|
||||
name="FriendshipOffered"
|
||||
type="notifytip">
|
||||
You have offered friendship to [TO_NAME]
|
||||
</notification>
|
||||
|
||||
<notification
|
||||
icon="notify.tga"
|
||||
name="OfferFriendshipNoMessage"
|
||||
|
||||
@@ -57,14 +57,9 @@
|
||||
mouse_opaque="true" name="Name:" v_pad="0" width="70">
|
||||
Name:
|
||||
</text>
|
||||
<name_editor bevel_style="in" border_style="line"
|
||||
border_thickness="1" bottom="-48" enabled="false" follows="left|top"
|
||||
font="SansSerifSmall" height="16" is_unicode="false" left_delta="75"
|
||||
max_length="254" mouse_opaque="false" name="name"
|
||||
width="180" visible="false" />
|
||||
<line_editor bevel_style="in" border_style="line"
|
||||
border_thickness="1" bottom="-48" enabled="false" follows="left|top"
|
||||
font="SansSerifSmall" height="16" is_unicode="false" left_delta="0"
|
||||
font="SansSerifSmall" height="16" is_unicode="false" left_delta="75"
|
||||
max_length="254" mouse_opaque="false" name="dnname"
|
||||
width="180" />
|
||||
<text bg_visible="false" border_drop_shadow_visible="false" border_visible="false"
|
||||
|
||||
@@ -3273,6 +3273,10 @@ The
|
||||
<string name="Region">Region</string>
|
||||
<string name="RegionSettings">Region Settings</string>
|
||||
|
||||
<!-- Multi Preview Floater -->
|
||||
<string name="MultiPreviewTitle">Preview</string>
|
||||
<string name="MultiPropertiesTitle">Properties</string>
|
||||
|
||||
<!-- inventory offer -->
|
||||
<string name="InvOfferAnObjectNamed">An object named</string>
|
||||
<string name="InvOfferOwnedByGroup">owned by the group</string>
|
||||
@@ -4015,6 +4019,9 @@ If you continue to receive this message, contact the [SUPPORT_SITE].
|
||||
<string name="answering-im">
|
||||
Connecting...
|
||||
</string>
|
||||
<string name="conference-title">
|
||||
Multi-person chat
|
||||
</string>
|
||||
<string name="inventory_item_offered-im">
|
||||
Inventory item offered
|
||||
</string>
|
||||
@@ -4247,6 +4254,8 @@ Try enclosing path to the editor with double quotes.
|
||||
<string name="BeaconMedia">Viewing media beacons (white)</string>
|
||||
<string name="ParticleHiding">Hiding Particles</string>
|
||||
|
||||
<string name="Command_Profile_Label">Profile</string>
|
||||
|
||||
<!-- Pathfinding -->
|
||||
<string name="Pathfinding_Wiki_URL">http://wiki.secondlife.com/wiki/Pathfinding_Tools_in_the_Second_Life_Viewer</string>
|
||||
<string name="Pathfinding_Object_Attr_None">None</string>
|
||||
|
||||
@@ -102,7 +102,6 @@
|
||||
</combo_box>
|
||||
<button label="Navegar" label_selected="Navegar" name="Browse"/>
|
||||
<button label="Buscar" label_selected="Buscar" name="Search"/>
|
||||
<button label="Poner un Anuncio..." label_selected="Poner un Anuncio..." name="Place an Ad..."/>
|
||||
<button label="Borrar" label_selected="Borrar" name="Delete"/>
|
||||
<scroll_list name="results">
|
||||
<column label="Nombre" name="name"/>
|
||||
|
||||
@@ -80,7 +80,6 @@
|
||||
</combo_box>
|
||||
<button label="Navegar" label_selected="Navegar" name="Browse"/>
|
||||
<button label="Buscar" label_selected="Buscar" name="Search"/>
|
||||
<button label="Poner un Anuncio..." label_selected="Poner un Anuncio..." name="Place an Ad..."/>
|
||||
<button label="Borrar" label_selected="Borrar" name="Delete"/>
|
||||
<scroll_list name="results">
|
||||
<column label="" name="icon"/>
|
||||
|
||||
@@ -129,7 +129,6 @@
|
||||
</combo_box>
|
||||
<button label="Navegar" label_selected="Navegar" name="Browse"/>
|
||||
<button label="Buscar" label_selected="Buscar" name="Search"/>
|
||||
<button label="Poner un Anuncio..." label_selected="Poner un Anuncio..." name="Place an Ad..."/>
|
||||
<button label="Borrar" label_selected="Borrar" name="Delete"/>
|
||||
<scroll_list name="results">
|
||||
<column label="" name="icon"/>
|
||||
|
||||
@@ -1384,13 +1384,6 @@ Aún puedes ver el chat y los MI existentes pulsando 'Ver MI y Chat'.
|
||||
No tienes el permiso de comprar terreno para el grupo que tienes activado actualmente.
|
||||
</notification>
|
||||
|
||||
<notification label="Añadir como amigo" name="AddFriend">
|
||||
Los amigos pueden darse permiso para localizarse en el mapa y para saber si el otro está conectado.
|
||||
|
||||
¿Ofrecer a [NAME] que sea tu amigo?
|
||||
<usetemplate name="okcancelbuttons" notext="Cancelar" yestext="OK"/>
|
||||
</notification>
|
||||
|
||||
<notification label="Añadir como amigo" name="AddFriendWithMessage">
|
||||
Los amigos pueden darse permiso para localizarse en el mapa y para saber si el otro está conectado.
|
||||
|
||||
@@ -3752,7 +3745,11 @@ Por favor, reinténtalo en unos momentos.
|
||||
<button name="Decline" text="Rehusar"/>
|
||||
</form>
|
||||
</notification>
|
||||
|
||||
|
||||
<notification name="FriendshipOffered">
|
||||
Has ofrecido amistad a [TO_NAME]
|
||||
</notification>
|
||||
|
||||
<notification name="OfferFriendshipNoMessage">
|
||||
[NAME] te está ofreciendo amistad.
|
||||
|
||||
|
||||
@@ -287,6 +287,7 @@
|
||||
<string name="connected">Conectado</string>
|
||||
<string name="unavailable">Chat de Voz no disponible en esta ubicación</string>
|
||||
<string name="hang_up">Desconectado del Chat de Voz</string>
|
||||
<string name="conference-title">Chat multi-persona</string>
|
||||
<string name="ScriptTakeMoney">Transferir moneda de tu cuenta</string>
|
||||
<string name="ActOnControlInputs">Actuar en tus controles de entrada</string>
|
||||
<string name="RemapControlInputs">Reconfigurar tus controles de entrada</string>
|
||||
@@ -3223,6 +3224,10 @@ La
|
||||
<string name="Region">Región</string>
|
||||
<string name="RegionSettings">Configuración de Región</string>
|
||||
|
||||
<!-- Multi Preview Floater -->
|
||||
<string name="MultiPreviewTitle">Vista previa</string>
|
||||
<string name="MultiPropertiesTitle">Propiedades</string>
|
||||
|
||||
<!-- inventory offer -->
|
||||
<string name="InvOfferAnObjectNamed">Un objeto llamado</string>
|
||||
<string name="InvOfferOwnedByGroup">propiedad del grupo</string>
|
||||
@@ -4209,6 +4214,8 @@ Intenta entrecomillando el camino al editor.
|
||||
<string name="BeaconMedia">Viendo balizas de medios (blanco)</string>
|
||||
<string name="ParticleHiding">Oocultando PartículasHiding Particlesstring>
|
||||
|
||||
<string name="Command_Profile_Label">Perfil</string>
|
||||
|
||||
<!-- Pathfinding -->
|
||||
<string name="Pathfinding_Wiki_URL">http://wiki.secondlife.com/wiki/Pathfinding_Tools_in_the_Second_Life_Viewer</string>
|
||||
<string name="Pathfinding_Object_Attr_None">Ninguno</string>
|
||||
|
||||
@@ -98,7 +98,6 @@
|
||||
</combo_box>
|
||||
<button label="Parcourir" label_selected="Parcourir" name="Browse"/>
|
||||
<button label="Rechercher" label_selected="Rechercher" name="Search" width="85"/>
|
||||
<button label="Passer une annonce" label_selected="Passer une annonce" name="Place an Ad..."/>
|
||||
<button label="Supprimer" label_selected="Supprimer" name="Delete"/>
|
||||
<scroll_list name="results">
|
||||
<column label="Nom" name="name"/>
|
||||
|
||||
@@ -1130,13 +1130,6 @@ Impossible d'acheter du terrain pour le groupe :
|
||||
Vous n'avez pas le droit d'acheter de terrain pour votre groupe.
|
||||
</notification>
|
||||
|
||||
<notification label="Devenir amis" name="AddFriend">
|
||||
Vous pouvez suivre les déplacements de vos amis sur la carte et voir lorsqu'ils se connectent.
|
||||
|
||||
Proposer à [NAME] de devenir votre ami(e).
|
||||
<usetemplate name="okcancelbuttons" notext="Annuler" yestext="OK"/>
|
||||
</notification>
|
||||
|
||||
<notification label="Devenir amis" name="AddFriendWithMessage">
|
||||
Vous pouvez suivre les déplacements de vos amis sur la carte et voir lorsqu'ils se connectent.
|
||||
|
||||
@@ -3385,6 +3378,10 @@ L'objet [OBJECTFROMNAME] appartenant à un utilisateur inconnu vous a donné un(
|
||||
</form>
|
||||
</notification>
|
||||
|
||||
<notification name="FriendshipOffered">
|
||||
Vous avez proposé à [TO_NAME] de devenir votre ami(e)
|
||||
</notification>
|
||||
|
||||
<notification name="OfferFriendshipNoMessage">
|
||||
[NAME] vous demande de devenir son ami.
|
||||
|
||||
|
||||
@@ -455,4 +455,16 @@
|
||||
<string name="choose_the_directory">
|
||||
Choisir le répertoire
|
||||
</string>
|
||||
<string name="conference-title">
|
||||
Chat à plusieurs
|
||||
</string>
|
||||
<string name="MultiPreviewTitle">
|
||||
Prévisualiser
|
||||
</string>
|
||||
<string name="MultiPropertiesTitle">
|
||||
Propriétés
|
||||
</string>
|
||||
<string name="Command_Profile_Label">
|
||||
Profil
|
||||
</string>
|
||||
</strings>
|
||||
|
||||
@@ -92,7 +92,6 @@
|
||||
</combo_box>
|
||||
<button label="Procura" label_selected="Procura" name="Browse"/>
|
||||
<button label="Buscar" label_selected="Buscar" name="Search"/>
|
||||
<button label="Colocar Anúncio..." label_selected="Colocar Anúncio..." name="Place an Ad..."/>
|
||||
<button label="Apagar" label_selected="Apagar" name="Delete"/>
|
||||
<scroll_list name="results">
|
||||
<column label="Nome" name="name"/>
|
||||
|
||||
@@ -1146,13 +1146,6 @@ Você ainda pode olhar o bate-papo e as mensagens instantâneas existentes, clic
|
||||
Você não tem permissão para comprar o terreno para o seu grupo ativado.
|
||||
</notification>
|
||||
|
||||
<notification label="Adicionar amigo" name="AddFriend">
|
||||
Amigos podem dar permissões de rastrear um ao outro pelo mapa e receber atualizações de status online.
|
||||
|
||||
Oferecer amizade para [NAME]?
|
||||
<usetemplate name="okcancelbuttons" notext="Cancelar" yestext="Oferecer"/>
|
||||
</notification>
|
||||
|
||||
<notification label="Adicionar amigo" name="AddFriendWithMessage">
|
||||
Amigos podem dar permissões de rastrear um ao outro pelo mapa e receber atualizações de status online.
|
||||
|
||||
@@ -3174,6 +3167,10 @@ Por favor, tente novamente em alguns instantes.
|
||||
</form>
|
||||
</notification>
|
||||
|
||||
<notification name="FriendshipOffered">
|
||||
Você convidou [TO_NAME] para ser seu amigo(a)
|
||||
</notification>
|
||||
|
||||
<notification name="OfferFriendshipNoMessage">
|
||||
[NAME] está lhe oferecendo sua amizade.
|
||||
|
||||
|
||||
@@ -205,4 +205,18 @@
|
||||
<string name="load_files">Carregar Arquivos</string>
|
||||
<string name="choose_the_directory">Escolher Diretório</string>
|
||||
|
||||
<string name="conference-title">
|
||||
Bate-papo com várias pessoas
|
||||
</string>
|
||||
|
||||
<string name="MultiPreviewTitle">
|
||||
Preview
|
||||
</string>
|
||||
<string name="MultiPropertiesTitle">
|
||||
Propriedades
|
||||
</string>
|
||||
|
||||
<string name="Command_Profile_Label">
|
||||
Perfil
|
||||
</string>
|
||||
</strings>
|
||||
|
||||
Reference in New Issue
Block a user