Merged in RLVa. Viewer broken!
This commit is contained in:
@@ -85,6 +85,13 @@
|
||||
#include "llvoavatar.h"
|
||||
#include "llvovolume.h"
|
||||
#include "pipeline.h"
|
||||
|
||||
#include "llglheaders.h"
|
||||
|
||||
// [RLVa:KB]
|
||||
#include "rlvhandler.h"
|
||||
// [/RLVa:KB]
|
||||
|
||||
// <edit>
|
||||
#include "llfloaterexport.h"
|
||||
// </edit>
|
||||
@@ -3436,6 +3443,7 @@ void LLSelectMgr::deselectUnused()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void LLSelectMgr::convertTransient()
|
||||
{
|
||||
LLObjectSelection::iterator node_it;
|
||||
@@ -3446,6 +3454,31 @@ void LLSelectMgr::convertTransient()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void LLSelectMgr::deselectUnused()
|
||||
{
|
||||
// no more outstanding references to this selection
|
||||
|
||||
// [RLVa:KB] - Checked: 2010-01-02 (RLVa-1.1.0l) | Modified: RLVa-1.1.0l
|
||||
#ifdef RLV_EXTENSION_CMD_INTERACT
|
||||
// [Fall-back code] Don't allow an active selection (except for HUD attachments - see above) when @interact=n restricted
|
||||
if (gRlvHandler.hasBehaviour(RLV_BHVR_INTERACT))
|
||||
{
|
||||
deselectAll();
|
||||
return;
|
||||
}
|
||||
#endif // RLV_EXTENSION_CMD_INTERACT
|
||||
// [/RLVa:KB]
|
||||
|
||||
// HACK: Don't deselect when we're navigating to rate an object's
|
||||
// owner or creator. JC
|
||||
if (gPieObject->getVisible() || gPieRate->getVisible() )
|
||||
if (mSelectedObjects->getNumRefs() == 1)
|
||||
{
|
||||
deselectAll();
|
||||
}
|
||||
}
|
||||
|
||||
void LLSelectMgr::deselectAllIfTooFar()
|
||||
{
|
||||
if (mSelectedObjects->isEmpty() || mSelectedObjects->mSelectType == SELECT_TYPE_HUD)
|
||||
@@ -3453,6 +3486,17 @@ void LLSelectMgr::deselectAllIfTooFar()
|
||||
return;
|
||||
}
|
||||
|
||||
// [RLVa:KB] - Checked: 2010-01-02 (RLVa-1.1.0l) | Modified: RLVa-1.1.0l
|
||||
#ifdef RLV_EXTENSION_CMD_INTERACT
|
||||
// [Fall-back code] Don't allow an active selection (except for HUD attachments - see above) when @interact=n restricted
|
||||
if (gRlvHandler.hasBehaviour(RLV_BHVR_INTERACT))
|
||||
{
|
||||
deselectAll();
|
||||
return;
|
||||
}
|
||||
#endif // RLV_EXTENSION_CMD_INTERACT
|
||||
// [/RLVa:KB]
|
||||
|
||||
// HACK: Don't deselect when we're navigating to rate an object's
|
||||
// owner or creator. JC
|
||||
if (gPieObject->getVisible() || gPieRate->getVisible() )
|
||||
@@ -3461,12 +3505,20 @@ void LLSelectMgr::deselectAllIfTooFar()
|
||||
}
|
||||
|
||||
LLVector3d selectionCenter = getSelectionCenterGlobal();
|
||||
if (gSavedSettings.getBOOL("LimitSelectDistance")
|
||||
|
||||
// if (gSavedSettings.getBOOL("LimitSelectDistance")
|
||||
// [RLVa:KB] - Checked: 2009-07-10 (RLVa-1.0.0g) | Modified: RLVa-0.2.0f
|
||||
BOOL fRlvFartouch = gRlvHandler.hasBehaviour(RLV_BHVR_FARTOUCH) && gFloaterTools->getVisible();
|
||||
if ( (gSavedSettings.getBOOL("LimitSelectDistance") || (fRlvFartouch) )
|
||||
// [/RLVa:KB]
|
||||
&& (!mSelectedObjects->getPrimaryObject() || !mSelectedObjects->getPrimaryObject()->isAvatar())
|
||||
&& !mSelectedObjects->isAttachment()
|
||||
&& !selectionCenter.isExactlyZero())
|
||||
{
|
||||
F32 deselect_dist = gSavedSettings.getF32("MaxSelectDistance");
|
||||
// F32 deselect_dist = gSavedSettings.getF32("MaxSelectDistance");
|
||||
// [RLVa:KB] - Checked: 2009-07-10 (RLVa-1.0.0g) | Modified: RLVa-0.2.0f
|
||||
F32 deselect_dist = (!fRlvFartouch) ? gSavedSettings.getF32("MaxSelectDistance") : 1.5f;
|
||||
// [/RLVa:KB]
|
||||
F32 deselect_dist_sq = deselect_dist * deselect_dist;
|
||||
|
||||
LLVector3d select_delta = gAgent.getPositionGlobal() - selectionCenter;
|
||||
@@ -3486,7 +3538,6 @@ void LLSelectMgr::deselectAllIfTooFar()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void LLSelectMgr::selectionSetObjectName(const std::string& name)
|
||||
{
|
||||
// we only work correctly if 1 object is selected.
|
||||
|
||||
Reference in New Issue
Block a user