PATH-807: BUGFIX Filtering which objects will contain the right-click context-sensitive menu option of "Show in linksets...".
parent
241a446224
commit
34d95fdc01
|
|
@ -2786,6 +2786,36 @@ BOOL LLSelectMgr::selectGetRootsNonCharacter()
|
|||
}
|
||||
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// selectGetEditableLinksets() - return TRUE if all objects are editable
|
||||
// pathfinding linksets
|
||||
//-----------------------------------------------------------------------------
|
||||
BOOL LLSelectMgr::selectGetEditableLinksets()
|
||||
{
|
||||
for (LLObjectSelection::iterator iter = getSelection()->begin();
|
||||
iter != getSelection()->end(); iter++ )
|
||||
{
|
||||
LLSelectNode* node = *iter;
|
||||
LLViewerObject* object = node->getObject();
|
||||
if( !object || !node->mValid )
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
if (object->flagUsePhysics() ||
|
||||
object->flagTemporaryOnRez() ||
|
||||
object->flagCharacter() ||
|
||||
object->flagAnimSource() ||
|
||||
(!gAgent.isGodlike() &&
|
||||
!gAgent.canManageEstate() &&
|
||||
!object->permYouOwner() &&
|
||||
!object->permMove()))
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// selectGetRootsTransfer() - return TRUE if current agent can transfer all
|
||||
// selected root objects.
|
||||
|
|
|
|||
|
|
@ -584,6 +584,8 @@ public:
|
|||
BOOL selectGetRootsNonCharacter();
|
||||
BOOL selectGetNonCharacter();
|
||||
|
||||
BOOL selectGetEditableLinksets();
|
||||
|
||||
// returns TRUE if selected objects can be transferred.
|
||||
BOOL selectGetRootsTransfer();
|
||||
|
||||
|
|
|
|||
|
|
@ -2804,7 +2804,7 @@ bool enable_object_build()
|
|||
|
||||
bool enable_object_select_in_pathfinding_linksets()
|
||||
{
|
||||
return LLPathfindingManager::getInstance()->isPathfindingEnabledForCurrentRegion() && LLSelectMgr::getInstance()->selectGetNonCharacter();
|
||||
return LLPathfindingManager::getInstance()->isPathfindingEnabledForCurrentRegion() && LLSelectMgr::getInstance()->selectGetEditableLinksets();
|
||||
}
|
||||
|
||||
bool enable_object_select_in_pathfinding_characters()
|
||||
|
|
|
|||
Loading…
Reference in New Issue