Ansariel 2022-10-21 01:51:04 +02:00
commit 401fa5a4e4
20 changed files with 113 additions and 28 deletions

View File

@ -30,7 +30,7 @@
#include "llerror.h"
// maximum reference count before sounding memory leak alarm
const S32 gMaxRefCount = 65536;
const S32 gMaxRefCount = S32_MAX;
LLRefCount::LLRefCount(const LLRefCount& other)
: mRef(0)

View File

@ -1 +1 @@
6.6.5
6.6.6

View File

@ -103,6 +103,7 @@
#include "stringize.h"
#include "boost/foreach.hpp"
#include "llcorehttputil.h"
#include "lluiusage.h"
// [RLVa:KB] - Checked: 2011-11-04 (RLVa-1.4.4a)
#include "rlvactions.h"
#include "rlvhandler.h"
@ -660,6 +661,8 @@ void LLAgent::ageChat()
//-----------------------------------------------------------------------------
void LLAgent::moveAt(S32 direction, bool reset)
{
LLUIUsage::instance().logCommand("Agent.MoveAt");
mMoveTimer.reset();
LLFirstUse::notMoving(false);
@ -4813,6 +4816,7 @@ void LLAgent::startTeleportRequest()
}
if (hasPendingTeleportRequest())
{
LLUIUsage::instance().logCommand("Agent.StartTeleportRequest");
mTeleportCanceled.reset();
if (!isMaturityPreferenceSyncedWithServer())
{

View File

@ -60,6 +60,8 @@
#include "llappviewer.h"
#include "llcoros.h"
#include "lleventcoro.h"
#include "lluiusage.h"
#include "llavatarpropertiesprocessor.h"
// [RLVa:KB] - Checked: 2011-05-22 (RLVa-1.3.1)
@ -1470,6 +1472,9 @@ void LLAppearanceMgr::wearItemsOnAvatar(const uuid_vec_t& item_ids_to_wear,
bool replace,
LLPointer<LLInventoryCallback> cb)
{
LL_DEBUGS("UIUsage") << "wearItemsOnAvatar" << LL_ENDL;
LLUIUsage::instance().logCommand("Avatar.WearItem");
bool first = true;
LLInventoryObject::const_object_list_t items_to_link;
@ -3133,6 +3138,7 @@ void LLAppearanceMgr::wearInventoryCategoryOnAvatar( LLInventoryCategory* catego
LL_INFOS("Avatar") << self_av_string() << "wearInventoryCategoryOnAvatar '" << category->getName()
<< "'" << LL_ENDL;
LLUIUsage::instance().logCommand("Avatar.WearCategory");
if (gAgentCamera.cameraCustomizeAvatar())
{
@ -4484,6 +4490,8 @@ void LLAppearanceMgr::makeNewOutfitLinks(const std::string& new_folder_name, boo
{
if (!isAgentAvatarValid()) return;
LLUIUsage::instance().logCommand("Avatar.CreateNewOutfit");
LL_DEBUGS("Avatar") << "creating new outfit" << LL_ENDL;
gAgentWearables.notifyLoadingStarted();
@ -4525,6 +4533,9 @@ void LLAppearanceMgr::wearBaseOutfit()
void LLAppearanceMgr::removeItemsFromAvatar(const uuid_vec_t& ids_to_remove, LLPointer<LLInventoryCallback> cb /*= NULL*/, bool immediate_delete /*= false*/)
// [/SL:KB]
{
LL_DEBUGS("UIUsage") << "removeItemsFromAvatar" << LL_ENDL;
LLUIUsage::instance().logCommand("Avatar.RemoveItem");
if (ids_to_remove.empty())
{
LL_WARNS() << "called with empty list, nothing to do" << LL_ENDL;
@ -5054,6 +5065,8 @@ public:
"Quick Appearance");
if ( gInventory.getCategory( folder_uuid ) != NULL )
{
// Assume this is coming from the predefined avatars web floater
LLUIUsage::instance().logCommand("Avatar.WearPredefinedAppearance");
LLAppearanceMgr::getInstance()->wearInventoryCategory(category, true, false);
// *TODOw: This may not be necessary if initial outfit is chosen already -- josh

View File

@ -78,6 +78,7 @@
#include "llsidepanelinventory.h"
#include "llavatarname.h"
#include "llagentui.h"
#include "lluiusage.h"
// [RLVa:KB] - Checked: 2011-04-11 (RLVa-1.3.0)
#include "rlvactions.h"
#include "rlvcommon.h"
@ -164,7 +165,7 @@ void LLAvatarActions::requestFriendshipDialog(const LLUUID& id, const std::strin
payload["id"] = id;
payload["name"] = name;
LLNotificationsUtil::add("AddFriendWithMessage", args, payload, &callbackAddFriendWithMessage);
LLNotificationsUtil::add("AddFriendWithMessage", args, payload, &callbackAddFriendWithMessage);
// add friend to recent people list
LLRecentPeople::instance().add(id);
@ -1788,6 +1789,8 @@ bool LLAvatarActions::handleUnfreeze(const LLSD& notification, const LLSD& respo
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);
LLUIUsage::instance().logCommand("Agent.SendFriendRequest");
send_improved_im(target_id,
target_name,
message,

View File

@ -53,6 +53,7 @@
#include "llviewerobjectlist.h"
#include "llvoavatar.h"
#include "llavataractions.h"
#include "lluiusage.h"
// Firestorm includes
#include "fscommon.h"
@ -302,6 +303,8 @@ void LLAvatarTracker::copyBuddyList(buddy_map_t& buddies) const
void LLAvatarTracker::terminateBuddy(const LLUUID& id)
{
LL_DEBUGS() << "LLAvatarTracker::terminateBuddy()" << LL_ENDL;
LLUIUsage::instance().logCommand("Agent.TerminateFriendship");
LLRelationship* buddy = get_ptr_in_map(mBuddyInfo, id);
if(!buddy) return;
mBuddyInfo.erase(id);

View File

@ -569,8 +569,6 @@ void LLChatBar::sendChatFromViewer(const LLWString &wtext, EChatType type, BOOL
// how to chat
gWarningSettings.setBOOL("FirstOtherChatBeforeUser", FALSE);
LLUIUsage::instance().logCommand("Chat.Send"); // Pseudo-command
// Look for "/20 foo" channel chats.
S32 channel = 0;
LLWString out_text = stripChannelNumber(wtext, &channel);

View File

@ -708,7 +708,6 @@ void LLFloaterIMNearbyChat::sendChatFromViewer(const std::string &utf8text, ECha
void LLFloaterIMNearbyChat::sendChatFromViewer(const LLWString &wtext, EChatType type, BOOL animate)
{
LLUIUsage::instance().logCommand("Chat.Send"); // pseuo-command
// Look for "/20 foo" channel chats.
S32 channel = 0;
LLWString out_text = stripChannelNumber(wtext, &channel);
@ -921,6 +920,12 @@ void send_chat_from_viewer(std::string utf8_out_text, EChatType type, S32 channe
}
// [/RLVa:KB]
LL_DEBUGS("UIUsage") << "Nearby chat, text " << utf8_out_text << " type " << type << " channel " << channel << LL_ENDL;
if (type != CHAT_TYPE_START && type != CHAT_TYPE_STOP) // prune back some redundant logging
{
LLUIUsage::instance().logCommand("Chat.SendNearby"); // pseuo-command
}
LLMessageSystem* msg = gMessageSystem;
if (channel >= 0)

View File

@ -64,6 +64,7 @@
#include "llviewerregion.h"
#include <boost/regex.hpp>
#include "llcorehttputil.h"
#include "lluiusage.h"
// [SL:KB] - Patch: Chat-GroupSessionEject | Checked: 2012-02-04 (Catznip-3.2.1)
#include "llimview.h"
@ -1881,6 +1882,9 @@ void LLGroupMgr::sendGroupRoleMemberChanges(const LLUUID& group_id)
//static
void LLGroupMgr::sendGroupMemberJoin(const LLUUID& group_id)
{
LLUIUsage::instance().logCommand("Group.Join");
LLMessageSystem *msg = gMessageSystem;
msg->newMessageFast(_PREHASH_JoinGroupRequest);

View File

@ -76,6 +76,7 @@
#include "message.h"
#include "llviewerregion.h"
#include "llcorehttputil.h"
#include "lluiusage.h"
// [RLVa:KB] - Checked: 2013-05-10 (RLVa-1.4.9)
#include "rlvactions.h"
#include "rlvcommon.h"
@ -911,6 +912,23 @@ void LLIMModel::LLIMSession::addMessage(const std::string& from, const LLUUID& f
message["index"] = (LLSD::Integer)mMsgs.size();
message["is_history"] = is_history;
LL_DEBUGS("UIUsage") << "addMessage " << " from " << from << " from_id " << from_id << " utf8_text " << utf8_text << " time " << time << " is_history " << is_history << " session mType " << mType << LL_ENDL;
if (from_id == gAgent.getID())
{
if (mType == IM_SESSION_GROUP_START)
{
LLUIUsage::instance().logCommand("Chat.SendGroup");
}
else if (mType == IM_NOTHING_SPECIAL)
{
LLUIUsage::instance().logCommand("Chat.SendIM");
}
else
{
LLUIUsage::instance().logCommand("Chat.SendOther");
}
}
mMsgs.push_front(message);
if (mSpeakers && from_id.notNull())

View File

@ -60,6 +60,7 @@
#include "llvoavatarself.h"
#include "llworld.h"
#include "llpanelface.h"
#include "lluiusage.h"
// [RLVa:KB] - Checked: 2011-05-22 (RLVa-1.3.1)
#include "rlvactions.h"
#include "rlvhandler.h"
@ -1323,10 +1324,12 @@ void LLToolDragAndDrop::dropObject(LLViewerObject* raycast_target,
LLMessageSystem* msg = gMessageSystem;
if (mSource == SOURCE_NOTECARD)
{
LLUIUsage::instance().logCommand("Object.RezObjectFromNotecard");
msg->newMessageFast(_PREHASH_RezObjectFromNotecard);
}
else
{
LLUIUsage::instance().logCommand("Object.RezObject");
msg->newMessageFast(_PREHASH_RezObject);
}
msg->nextBlockFast(_PREHASH_AgentData);

View File

@ -74,6 +74,7 @@
#include "llui.h"
#include "llweb.h"
#include "pipeline.h" // setHighlightObject
#include "lluiusage.h"
// [RLVa:KB] - Checked: 2010-03-06 (RLVa-1.2.0c)
#include "rlvactions.h"
#include "rlvhandler.h"
@ -647,6 +648,8 @@ bool LLToolPie::walkToClickedLocation()
return false;
}
LLUIUsage::instance().logCommand("Agent.WalkToClickedLocation");
LLPickInfo saved_pick = mPick;
if (gAgentCamera.getCameraMode() != CAMERA_MODE_MOUSELOOK)
{

View File

@ -66,6 +66,7 @@
#include "llprimitive.h"
#include "llwindow.h" // incBusyCount()
#include "material_codes.h"
#include "lluiusage.h"
// [RLVa:KB] - Checked: 2010-03-23 (RLVa-1.2.0a)
#include "rlvhandler.h"
@ -301,6 +302,7 @@ BOOL LLToolPlacer::addObject( LLPCode pcode, S32 x, S32 y, U8 use_physics )
gAgent.getID(), 1.0f, LLAudioEngine::AUDIO_TYPE_UI);
}
LLUIUsage::instance().logCommand("Build.ObjectAdd");
gMessageSystem->newMessageFast(_PREHASH_ObjectAdd);
gMessageSystem->nextBlockFast(_PREHASH_AgentData);
gMessageSystem->addUUIDFast(_PREHASH_AgentID, gAgent.getID());

View File

@ -3950,7 +3950,7 @@ bool LLViewerMediaImpl::shouldShowBasedOnClass() const
//
bool LLViewerMediaImpl::isObscured() const
{
if (getUsedInUI() || isParcelMedia()) return false;
if (getUsedInUI() || isParcelMedia() || isAttachedToHUD()) return false;
LLParcel* agent_parcel = LLViewerParcelMgr::getInstance()->getAgentParcel();
if (!agent_parcel)
@ -3966,6 +3966,20 @@ bool LLViewerMediaImpl::isObscured() const
return false;
}
bool LLViewerMediaImpl::isAttachedToHUD() const
{
std::list< LLVOVolume* >::const_iterator iter = mObjectList.begin();
std::list< LLVOVolume* >::const_iterator end = mObjectList.end();
for ( ; iter != end; iter++)
{
if ((*iter)->isHUDAttachment())
{
return true;
}
}
return false;
}
//////////////////////////////////////////////////////////////////////////////////////////
//
bool LLViewerMediaImpl::isAttachedToAnotherAvatar() const

View File

@ -411,6 +411,8 @@ public:
void cancelMimeTypeProbe();
bool isAttachedToHUD() const;
// Is this media attached to an avatar *not* self
bool isAttachedToAnotherAvatar() const;

View File

@ -134,6 +134,7 @@
#include "llexperiencecache.h"
#include "llexperiencecache.h"
#include "lluiusage.h"
// Firestorm includes
#include <boost/regex.hpp>
@ -322,6 +323,7 @@ bool friendship_offer_callback(const LLSD& notification, const LLSD& response)
{
case 0:
{
LLUIUsage::instance().logCommand("Agent.AcceptFriendship");
// accept
LLAvatarTracker::formFriendship(payload["from_id"]);
@ -370,6 +372,7 @@ bool friendship_offer_callback(const LLSD& notification, const LLSD& response)
// fall-through
case 2: // Send IM - decline and start IM session
{
LLUIUsage::instance().logCommand("Agent.DeclineFriendship");
// decline
// We no longer notify other viewers, but we DO still send
// the rejection to the simulator to delete the pending userop.
@ -917,6 +920,11 @@ void send_join_group_response(LLUUID group_id, LLUUID transaction_id, bool accep
EInstantMessage type = accept_invite ? IM_GROUP_INVITATION_ACCEPT : IM_GROUP_INVITATION_DECLINE;
if (accept_invite)
{
LLUIUsage::instance().logCommand("Group.Join");
}
send_improved_im(group_id,
std::string("name"),
std::string("message"),

View File

@ -331,6 +331,24 @@ void LLViewerRegionImpl::requestBaseCapabilitiesCoro(U64 regionHandle)
return;
}
if (!LLWorld::instanceExists())
{
LL_WARNS("AppInit", "Capabilities") << "Received capabilities, but world no longer exists!" << LL_ENDL;
return;
}
regionp = LLWorld::getInstance()->getRegionFromHandle(regionHandle);
if (!regionp) //region was removed
{
LL_WARNS("AppInit", "Capabilities") << "Received capabilities for region that no longer exists!" << LL_ENDL;
return; // this error condition is not recoverable.
}
impl = regionp->getRegionImplNC();
// <FS:Ansariel> Fix seed cap retry count
//++(impl->mSeedCapAttempts);
if (!result.isMap() || result.has("error"))
{
LL_WARNS("AppInit", "Capabilities") << "Malformed response" << LL_ENDL;
@ -350,24 +368,6 @@ void LLViewerRegionImpl::requestBaseCapabilitiesCoro(U64 regionHandle)
// remove the http_result from the llsd
result.erase("http_result");
if (!LLWorld::instanceExists())
{
LL_WARNS("AppInit", "Capabilities") << "Received capabilities, but world no longer exists!" << LL_ENDL;
return;
}
regionp = LLWorld::getInstance()->getRegionFromHandle(regionHandle);
if (!regionp) //region was removed
{
LL_WARNS("AppInit", "Capabilities") << "Received capabilities for region that no longer exists!" << LL_ENDL;
return; // this error condition is not recoverable.
}
impl = regionp->getRegionImplNC();
// <FS:Ansariel> Fix seed cap retry count
//++(impl->mSeedCapAttempts);
if (id != impl->mHttpResponderID) // region is no longer referring to this request
{
LL_WARNS("AppInit", "Capabilities") << "Received results for a stale capabilities request!" << LL_ENDL;

View File

@ -67,6 +67,7 @@
#include "llsdserialize.h"
#include "llcallstack.h"
#include "llcorehttputil.h"
#include "lluiusage.h"
// Firestorm includes
#include "fslslbridge.h"
@ -3242,6 +3243,7 @@ void LLVOAvatarSelf::onCustomizeStart(bool disable_camera_switch)
{
if (isAgentAvatarValid())
{
LLUIUsage::instance().logCommand("Avatar.CustomizeStart");
if (!gAgentAvatarp->mEndCustomizeCallback.get())
{
gAgentAvatarp->mEndCustomizeCallback = new LLUpdateAppearanceOnDestroy;

View File

@ -37,6 +37,7 @@
#include "llui.h"
#include "llkeyboard.h"
#include "llagent.h"
#include "lluiusage.h"
const F32 LLVoiceClient::OVERDRIVEN_POWER_LEVEL = 0.7f;
@ -619,6 +620,10 @@ void LLVoiceClient::setMuteMic(bool muted)
void LLVoiceClient::setUserPTTState(bool ptt)
{
if (ptt)
{
LLUIUsage::instance().logCommand("Agent.EnableMicrophone");
}
mUserPTTState = ptt;
updateMicMuteLogic();
mMicroChangedSignal();

View File

@ -6395,7 +6395,7 @@ void LLVolumeGeometryManager::rebuildMesh(LLSpatialGroup* group)
{
LLDrawable* drawablep = (LLDrawable*)(*drawable_iter)->getDrawable();
if (drawablep && !drawablep->isDead() && drawablep->isState(LLDrawable::REBUILD_ALL) && !drawablep->isState(LLDrawable::RIGGED) )
if (drawablep && !drawablep->isDead() && drawablep->isState(LLDrawable::REBUILD_ALL))
{
LL_PROFILE_ZONE_NAMED_CATEGORY_VOLUME("Rebuild all non-Rigged");
LLVOVolume* vobj = drawablep->getVOVolume();
@ -6440,8 +6440,6 @@ void LLVolumeGeometryManager::rebuildMesh(LLSpatialGroup* group)
LLVertexBuffer* buff = face->getVertexBuffer();
if (buff)
{
llassert(!face->isState(LLFace::RIGGED));
if (!face->getGeometryVolume(*volume, face->getTEOffset(),
vobj->getRelativeXform(), vobj->getRelativeXformInvTrans(), face->getGeomIndex()))
{ //something's gone wrong with the vertex buffer accounting, rebuild this group