diff options
| author | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2023-07-26 00:59:09 +0300 | 
|---|---|---|
| committer | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2023-07-26 00:59:32 +0300 | 
| commit | 24f9b1f6dae69a642f8446e9bba4c2586f076594 (patch) | |
| tree | fdb76eeaaa7f6959a2ea8fce54093f93bd3dbecf /indra | |
| parent | 0a014776b3361cf6b7126f50f9e7d2f2b2eb04a5 (diff) | |
SL-20049 Don't show selection beam when attempting to drag avatar
Diffstat (limited to 'indra')
| -rw-r--r-- | indra/newview/llvoavatarself.cpp | 16 | 
1 files changed, 9 insertions, 7 deletions
| diff --git a/indra/newview/llvoavatarself.cpp b/indra/newview/llvoavatarself.cpp index 914376f5d1..b03d32d291 100644 --- a/indra/newview/llvoavatarself.cpp +++ b/indra/newview/llvoavatarself.cpp @@ -960,7 +960,7 @@ void LLVOAvatarSelf::updateRegion(LLViewerRegion *regionp)  }  //-------------------------------------------------------------------- -// draw tractor beam when editing objects +// draw tractor (selection) beam when editing objects  //--------------------------------------------------------------------  //virtual  void LLVOAvatarSelf::idleUpdateTractorBeam() @@ -2821,12 +2821,14 @@ BOOL LLVOAvatarSelf::needsRenderBeam()  	LLTool *tool = LLToolMgr::getInstance()->getCurrentTool();  	BOOL is_touching_or_grabbing = (tool == LLToolGrab::getInstance() && LLToolGrab::getInstance()->isEditing()); -	if (LLToolGrab::getInstance()->getEditingObject() &&  -		LLToolGrab::getInstance()->getEditingObject()->isAttachment()) -	{ -		// don't render selection beam on hud objects -		is_touching_or_grabbing = FALSE; -	} +    LLViewerObject* objp = LLToolGrab::getInstance()->getEditingObject(); +    if (objp // might need to be "!objp ||" instead of "objp &&". +        && (objp->isAttachment() || objp->isAvatar())) +    { +        // don't render grab tool's selection beam on hud objects, +        // attachments or avatars +        is_touching_or_grabbing = FALSE; +    }  	return is_touching_or_grabbing || (getAttachmentState() & AGENT_STATE_EDITING && LLSelectMgr::getInstance()->shouldShowSelection());  } | 
