Merge branch 'DRTVWR-503-maint' of https://bitbucket.org/lindenlab/viewer

master
Ansariel 2020-07-29 13:35:01 +02:00
commit 3f1f5e884b
9 changed files with 21 additions and 33 deletions

View File

@ -1312,6 +1312,7 @@ Shyotl Kuhr
MAINT-2334
MAINT-6913
STORM-2143
SL-11625
Siana Gearz
STORM-960
STORM-1088
@ -1351,6 +1352,7 @@ Sovereign Engineer
MAINT-7343
SL-11079
OPEN-343
SL-11625
SpacedOut Frye
VWR-34
VWR-45

View File

@ -4561,6 +4561,7 @@ void LLFloaterPreferenceGraphicsAdvanced::onClickCloseBtn(bool app_quitting)
{
instance->cancel();
}
updateMaxComplexity();
}
LLFloaterPreferenceProxy::~LLFloaterPreferenceProxy()

View File

@ -462,17 +462,19 @@ void LLHUDNameTag::addLine(const std::string &text_utf8,
U32 line_length = 0;
if (use_ellipses)
{
// "QualityAssuranceAssuresQuality 1" will end up like "QualityAssuranceAssuresQual..."
// "QualityAssurance AssuresQuality 1" will be split into two lines "QualityAssurance" and "AssuresQuality 1"
// "QualityAssuranceAssuresQuality1" will end up like "QualityAssuranceAssuresQual..."
// "QualityAssuranceAssuresQuality QualityAssuranceAssuresQuality" will end up like "QualityAssuranceAssuresQual..."
// "QualityAssurance AssuresQuality1" will end up as "QualityAssurance AssuresQua..." because we are enforcing single line
do
{
S32 segment_length = font->maxDrawableChars(iter->substr(line_length).c_str(), max_pixels, wline.length(), LLFontGL::ONLY_WORD_BOUNDARIES);
if (segment_length == 0)
S32 segment_length = font->maxDrawableChars(iter->substr(line_length).c_str(), max_pixels, wline.length(), LLFontGL::ANYWHERE);
if (segment_length + line_length < wline.length()) // since we only draw one string, line_length should be 0
{
// First word in segment (not nessesary first line) does not fit, need to draw "...".
// token does does not fit into signle line, need to draw "...".
// Use four dots for ellipsis width to generate padding
const LLWString dots_pad(utf8str_to_wstring(std::string("....")));
S32 elipses_width = font->getWidthF32(dots_pad.c_str());
// truncated string length
segment_length = font->maxDrawableChars(iter->substr(line_length).c_str(), max_pixels - elipses_width, wline.length(), LLFontGL::ANYWHERE);
const LLWString dots(utf8str_to_wstring(std::string("...")));
LLHUDTextSegment segment(iter->substr(line_length, segment_length) + dots, style, color, font);
@ -481,6 +483,7 @@ void LLHUDNameTag::addLine(const std::string &text_utf8,
}
else
{
// token fits fully into string
LLHUDTextSegment segment(iter->substr(line_length, segment_length), style, color, font);
mTextSegments.push_back(segment);
line_length += segment_length;

View File

@ -4066,11 +4066,11 @@ BOOL LLSelectMgr::selectGetAggregateTexturePermissions(LLAggregatePermissions& r
return TRUE;
}
BOOL LLSelectMgr::isSelfAvatarSelected()
BOOL LLSelectMgr::isMovableAvatarSelected()
{
if (mAllowSelectAvatar)
{
return (getSelection()->getObjectCount() == 1) && (getSelection()->getFirstRootObject() == gAgentAvatarp);
return (getSelection()->getObjectCount() == 1) && (getSelection()->getFirstRootObject()->isAvatar()) && getSelection()->getFirstMoveableNode(TRUE);
}
return FALSE;
}

View File

@ -811,7 +811,7 @@ public:
LLPermissions* findObjectPermissions(const LLViewerObject* object);
BOOL isSelfAvatarSelected();
BOOL isMovableAvatarSelected();
void selectDelete(); // Delete on simulator
void selectForceDelete(); // just delete, no into trash

View File

@ -253,7 +253,6 @@ U32 LLViewerJointMesh::drawShape( F32 pixelArea, BOOL first_pass, BOOL is_dummy)
//----------------------------------------------------------------
llassert( !(mTexture.notNull() && mLayerSet) ); // mutually exclusive
// LLTexUnit::eTextureAddressMode old_mode = LLTexUnit::TAM_WRAP; // <FS> Rye Mutt's broken local texture rendering fix
LLViewerTexLayerSet *layerset = dynamic_cast<LLViewerTexLayerSet*>(mLayerSet);
if (mTestImageName)
{
@ -280,24 +279,15 @@ U32 LLViewerJointMesh::drawShape( F32 pixelArea, BOOL first_pass, BOOL is_dummy)
gGL.getTexUnit(diffuse_channel)->bind(LLViewerTextureManager::getFetchedTexture(IMG_DEFAULT));
}
}
else
if ( !is_dummy && mTexture.notNull() )
else if ( !is_dummy && mTexture.notNull() )
{
// <FS> Rye Mutt's broken local texture rendering fix
//if(mTexture->hasGLTexture())
//{
// old_mode = mTexture->getAddressMode();
//}
// </FS>
gGL.getTexUnit(diffuse_channel)->bind(mTexture);
//gGL.getTexUnit(diffuse_channel)->setTextureAddressMode(LLTexUnit::TAM_CLAMP); // <FS> Rye Mutt's broken local texture rendering fix
}
else
{
gGL.getTexUnit(diffuse_channel)->bind(LLViewerTextureManager::getFetchedTexture(IMG_DEFAULT));
}
U32 mask = sRenderMask;
U32 start = mMesh->mFaceVertexOffset;
@ -343,14 +333,6 @@ U32 LLViewerJointMesh::drawShape( F32 pixelArea, BOOL first_pass, BOOL is_dummy)
gGL.getTexUnit(diffuse_channel)->setTextureBlendType(LLTexUnit::TB_MULT);
}
// <FS> Rye Mutt's broken local texture rendering fix
//if (mTexture.notNull() && !is_dummy)
//{
// gGL.getTexUnit(diffuse_channel)->bind(mTexture);
// gGL.getTexUnit(diffuse_channel)->setTextureAddressMode(old_mode);
//}
// </FS>
return triangle_count;
}

View File

@ -1988,7 +1988,10 @@ void LLViewerParcelMgr::processParcelProperties(LLMessageSystem *msg, void **use
|| music_url.substr(0, 8) == "https://")
{
LLViewerRegion *region = LLWorld::getInstance()->getRegion(msg->getSender());
optionally_start_music(music_url, parcel->mLocalID, region->getRegionID());
if (region)
{
optionally_start_music(music_url, parcel->mLocalID, region->getRegionID());
}
}
else
{

View File

@ -60,10 +60,7 @@ LLViewerTexLayerSetBuffer::LLViewerTexLayerSetBuffer(LLTexLayerSet* const owner,
S32 width, S32 height) :
// ORDER_LAST => must render these after the hints are created.
LLTexLayerSetBuffer(owner),
// <FS> Rye Mutt's broken local texture rendering fix
//LLViewerDynamicTexture( width, height, 4, LLViewerDynamicTexture::ORDER_LAST, TRUE ),
LLViewerDynamicTexture( width, height, 4, LLViewerDynamicTexture::ORDER_LAST, FALSE ),
// </FS>
LLViewerDynamicTexture(width, height, 4, LLViewerDynamicTexture::ORDER_LAST, FALSE),
// <FS:Ansariel> [Legacy Bake]
mUploadPending(FALSE), // Not used for any logic here, just to sync sending of updates
mNeedsUpload(FALSE),

View File

@ -5030,7 +5030,7 @@ void LLViewerWindow::renderSelections( BOOL for_gl_pick, BOOL pick_parcel_walls,
BOOL draw_handles = TRUE;
if (tool == LLToolCompTranslate::getInstance() && !all_selected_objects_move && !LLSelectMgr::getInstance()->isSelfAvatarSelected())
if (tool == LLToolCompTranslate::getInstance() && !all_selected_objects_move && !LLSelectMgr::getInstance()->isMovableAvatarSelected())
{
draw_handles = FALSE;
}