From b923f6f671b164dfbc0d3d6137076764b3f22666 Mon Sep 17 00:00:00 2001 From: Mnikolenko Productengine Date: Mon, 11 Sep 2023 19:49:19 +0300 Subject: SL-20277 remove settings from camera presets --- indra/newview/app_settings/camera/Front.xml | 22 ---------------------- indra/newview/app_settings/camera/Rear.xml | 22 ---------------------- indra/newview/app_settings/camera/Side.xml | 22 ---------------------- indra/newview/llpresetsmanager.cpp | 2 -- 4 files changed, 68 deletions(-) diff --git a/indra/newview/app_settings/camera/Front.xml b/indra/newview/app_settings/camera/Front.xml index 39f44e11a8..f96d3bc779 100644 --- a/indra/newview/app_settings/camera/Front.xml +++ b/indra/newview/app_settings/camera/Front.xml @@ -1,16 +1,5 @@ - AppearanceCameraMovement - - Comment - When entering appearance editing mode, camera zooms in on currently selected portion of avatar - Persist - 1 - Type - Boolean - Value - 1 - AvatarSitRotation Comment @@ -90,17 +79,6 @@ Value 0.90322577953338623 - EditCameraMovement - - Comment - When entering build mode, camera moves up above avatar - Persist - 1 - Type - Boolean - Value - 0 - FocusOffsetRearView Comment diff --git a/indra/newview/app_settings/camera/Rear.xml b/indra/newview/app_settings/camera/Rear.xml index 8dc36353ce..7eda566e48 100644 --- a/indra/newview/app_settings/camera/Rear.xml +++ b/indra/newview/app_settings/camera/Rear.xml @@ -1,16 +1,5 @@ - AppearanceCameraMovement - - Comment - When entering appearance editing mode, camera zooms in on currently selected portion of avatar - Persist - 1 - Type - Boolean - Value - 1 - AvatarSitRotation Comment @@ -90,17 +79,6 @@ Value 0.90322577953338623 - EditCameraMovement - - Comment - When entering build mode, camera moves up above avatar - Persist - 1 - Type - Boolean - Value - 0 - FocusOffsetRearView Comment diff --git a/indra/newview/app_settings/camera/Side.xml b/indra/newview/app_settings/camera/Side.xml index 089ab93a8f..77f73f1df1 100644 --- a/indra/newview/app_settings/camera/Side.xml +++ b/indra/newview/app_settings/camera/Side.xml @@ -1,16 +1,5 @@ - AppearanceCameraMovement - - Comment - When entering appearance editing mode, camera zooms in on currently selected portion of avatar - Persist - 1 - Type - Boolean - Value - 1 - AvatarSitRotation Comment @@ -90,17 +79,6 @@ Value 0.90322577953338623 - EditCameraMovement - - Comment - When entering build mode, camera moves up above avatar - Persist - 1 - Type - Boolean - Value - 0 - FocusOffsetRearView Comment diff --git a/indra/newview/llpresetsmanager.cpp b/indra/newview/llpresetsmanager.cpp index 30d0a22ef0..bc77588b9f 100644 --- a/indra/newview/llpresetsmanager.cpp +++ b/indra/newview/llpresetsmanager.cpp @@ -254,8 +254,6 @@ void LLPresetsManager::getControlNames(std::vector& names) // From panel_preferences_move.xml ("CameraAngle") ("CameraOffsetScale") - ("EditCameraMovement") - ("AppearanceCameraMovement") // From llagentcamera.cpp ("CameraOffsetBuild") ("TrackFocusObject") -- cgit v1.2.3 From f01d0dba2b9b1e0bb61a771ccabf17a12c92bfa0 Mon Sep 17 00:00:00 2001 From: Alexander Gavriliuk Date: Fri, 15 Sep 2023 01:37:56 +0200 Subject: SL-20279 BugSplat Crash #1327171: gl_debug_callback(111) --- indra/llrender/llgl.cpp | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/indra/llrender/llgl.cpp b/indra/llrender/llgl.cpp index cfc9ce735d..44f7667d2c 100644 --- a/indra/llrender/llgl.cpp +++ b/indra/llrender/llgl.cpp @@ -93,6 +93,17 @@ void APIENTRY gl_debug_callback(GLenum source, return; } + if (gGLManager.mIsDisabled && + severity == GL_DEBUG_SEVERITY_HIGH_ARB && + source == GL_DEBUG_SOURCE_API_ARB && + type == GL_DEBUG_TYPE_ERROR_ARB && + id == GL_INVALID_VALUE) + { + // Suppress messages about deleting already deleted objects called from LLViewerWindow::stopGL() + // "GL_INVALID_VALUE error generated. Handle does not refer to an object generated by OpenGL." + return; + } + if (severity == GL_DEBUG_SEVERITY_HIGH_ARB) { LL_WARNS() << "----- GL ERROR --------" << LL_ENDL; @@ -106,7 +117,8 @@ void APIENTRY gl_debug_callback(GLenum source, LL_WARNS() << "Severity: " << std::hex << severity << LL_ENDL; LL_WARNS() << "Message: " << message << LL_ENDL; LL_WARNS() << "-----------------------" << LL_ENDL; - if (severity == GL_DEBUG_SEVERITY_HIGH_ARB) + // No needs to halt when is called from LLViewerWindow::stopGL() + if (severity == GL_DEBUG_SEVERITY_HIGH_ARB && !gGLManager.mIsDisabled) { LL_ERRS() << "Halting on GL Error" << LL_ENDL; } -- cgit v1.2.3 From 06dd9c31476218a8bb097887971668d10590b5e5 Mon Sep 17 00:00:00 2001 From: Alexander Gavriliuk Date: Sat, 2 Sep 2023 12:35:35 +0200 Subject: SL-20236 BugSplat Crash in LLVertexBuffer::validateRange(708) --- indra/newview/llvopartgroup.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/indra/newview/llvopartgroup.cpp b/indra/newview/llvopartgroup.cpp index 51cf5f20c6..02f5313db9 100644 --- a/indra/newview/llvopartgroup.cpp +++ b/indra/newview/llvopartgroup.cpp @@ -607,7 +607,7 @@ void LLVOPartGroup::getGeometry(const LLViewerPart& part, up.setCross3(right, at); up.normalize3fast(); - if (part.mFlags & LLPartData::LL_PART_FOLLOW_VELOCITY_MASK) + if (part.mFlags & LLPartData::LL_PART_FOLLOW_VELOCITY_MASK && !part.mVelocity.isExactlyZero()) { LLVector4a normvel; normvel.load3(part.mVelocity.mV); -- cgit v1.2.3 From 51346ddbb0895815a288465b8751bc8b1c6c2d33 Mon Sep 17 00:00:00 2001 From: Alexander Gavriliuk Date: Wed, 20 Sep 2023 00:08:31 +0200 Subject: SL-20280 BugSplat Crash in LLVertexBuffer::setBuffer() --- indra/llrender/llvertexbuffer.cpp | 59 --------------------------------------- 1 file changed, 59 deletions(-) diff --git a/indra/llrender/llvertexbuffer.cpp b/indra/llrender/llvertexbuffer.cpp index be3e6ddff0..937b8c74ff 100644 --- a/indra/llrender/llvertexbuffer.cpp +++ b/indra/llrender/llvertexbuffer.cpp @@ -2181,65 +2181,6 @@ void LLVertexBuffer::setBuffer(U32 data_mask) //set up pointers if the data mask is different ... bool setup = (sLastMask != data_mask); - if (gDebugGL && data_mask != 0) - { //make sure data requirements are fulfilled - LLGLSLShader* shader = LLGLSLShader::sCurBoundShaderPtr; - if (shader) - { - U32 required_mask = 0; - for (U32 i = 0; i < LLVertexBuffer::TYPE_TEXTURE_INDEX; ++i) - { - if (shader->getAttribLocation(i) > -1) - { - U32 required = 1 << i; - if ((data_mask & required) == 0) - { - LL_WARNS() << "Missing attribute: " << LLShaderMgr::instance()->mReservedAttribs[i] << LL_ENDL; - } - - required_mask |= required; - } - } - - if ((data_mask & required_mask) != required_mask) - { - - U32 unsatisfied_mask = (required_mask & ~data_mask); - - for (U32 i = 0; i < TYPE_MAX; i++) - { - U32 unsatisfied_flag = unsatisfied_mask & (1 << i); - switch (unsatisfied_flag) - { - case 0: break; - case MAP_VERTEX: LL_INFOS() << "Missing vert pos" << LL_ENDL; break; - case MAP_NORMAL: LL_INFOS() << "Missing normals" << LL_ENDL; break; - case MAP_TEXCOORD0: LL_INFOS() << "Missing TC 0" << LL_ENDL; break; - case MAP_TEXCOORD1: LL_INFOS() << "Missing TC 1" << LL_ENDL; break; - case MAP_TEXCOORD2: LL_INFOS() << "Missing TC 2" << LL_ENDL; break; - case MAP_TEXCOORD3: LL_INFOS() << "Missing TC 3" << LL_ENDL; break; - case MAP_COLOR: LL_INFOS() << "Missing vert color" << LL_ENDL; break; - case MAP_EMISSIVE: LL_INFOS() << "Missing emissive" << LL_ENDL; break; - case MAP_TANGENT: LL_INFOS() << "Missing tangent" << LL_ENDL; break; - case MAP_WEIGHT: LL_INFOS() << "Missing weight" << LL_ENDL; break; - case MAP_WEIGHT4: LL_INFOS() << "Missing weightx4" << LL_ENDL; break; - case MAP_CLOTHWEIGHT: LL_INFOS() << "Missing clothweight" << LL_ENDL; break; - case MAP_TEXTURE_INDEX: LL_INFOS() << "Missing tex index" << LL_ENDL; break; - default: LL_INFOS() << "Missing who effin knows: " << unsatisfied_flag << LL_ENDL; - } - } - - // TYPE_INDEX is beyond TYPE_MAX, so check for it individually - if (unsatisfied_mask & (1 << TYPE_INDEX)) - { - LL_INFOS() << "Missing indices" << LL_ENDL; - } - - LL_ERRS() << "Shader consumption mismatches data provision." << LL_ENDL; - } - } - } - if (useVBOs()) { if (mGLArray) -- cgit v1.2.3 From dc57c88e7ff8043d4413573ad72869d51bdb1d0d Mon Sep 17 00:00:00 2001 From: Alexander Gavriliuk Date: Thu, 21 Sep 2023 01:07:56 +0200 Subject: SL-20287 The 'search_history.txt' file in the user profile is always empty --- indra/newview/llsearchhistory.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/indra/newview/llsearchhistory.cpp b/indra/newview/llsearchhistory.cpp index 449e0080f0..66e377cb8d 100644 --- a/indra/newview/llsearchhistory.cpp +++ b/indra/newview/llsearchhistory.cpp @@ -75,6 +75,17 @@ bool LLSearchHistory::save() { // build filename for each user std::string resolved_filename = getHistoryFilePath(); + + // delete the file if it is empty or contains only empty entries + if (std::find_if(mSearchHistory.begin(), mSearchHistory.end(), [](const LLSearchHistoryItem& x) + { + return !x.search_query.empty(); + }) == mSearchHistory.end()) + { + remove(resolved_filename.c_str()); + return true; + } + // open a file for writing llofstream file(resolved_filename.c_str()); if (!file.is_open()) -- cgit v1.2.3 From ac0299fc7cef28720533947154d34aa1e006e720 Mon Sep 17 00:00:00 2001 From: Alexander Gavriliuk Date: Fri, 22 Sep 2023 11:10:40 +0200 Subject: SL-20244 Log crash reason before assertion in check_rigged_group() --- indra/newview/llspatialpartition.cpp | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp index 17c834326c..39ed23e131 100644 --- a/indra/newview/llspatialpartition.cpp +++ b/indra/newview/llspatialpartition.cpp @@ -1632,6 +1632,8 @@ bool check_rigged_group(LLDrawable* drawable) if (root->isState(LLDrawable::RIGGED) && root->getSpatialGroup() != group) { + LL_WARNS() << "[root->isState(LLDrawable::RIGGED) and root->getSpatialGroup() != group] is true" + " (" << root->getSpatialGroup() << " != " << group << ")" << LL_ENDL; llassert(false); return false; } @@ -1641,8 +1643,10 @@ bool check_rigged_group(LLDrawable* drawable) { for (auto& face : root->getFaces()) { - if ((S32) face->getDrawOrderIndex() <= last_draw_index) + if ((S32)face->getDrawOrderIndex() <= last_draw_index) { + LL_WARNS() << "[(S32)face->getDrawOrderIndex() <= last_draw_index] is true" + " (" << (S32)face->getDrawOrderIndex() << " <= " << last_draw_index << ")" << LL_ENDL; llassert(false); return false; } @@ -1656,17 +1660,21 @@ bool check_rigged_group(LLDrawable* drawable) { for (auto& face : child->mDrawable->getFaces()) { - if ((S32) face->getDrawOrderIndex() <= last_draw_index) + if ((S32)face->getDrawOrderIndex() <= last_draw_index) { + LL_WARNS() << "[(S32)face->getDrawOrderIndex() <= last_draw_index] is true" + " (" << (S32)face->getDrawOrderIndex() << " <= " << last_draw_index << ")" << LL_ENDL; llassert(false); return false; } last_draw_index = face->getDrawOrderIndex(); } } - + if (child->mDrawable->getSpatialGroup() != group) { + LL_WARNS() << "[child->mDrawable->getSpatialGroup() != group] is true" + " (" << child->mDrawable->getSpatialGroup() << " != " << group << ")" << LL_ENDL; llassert(false); return false; } -- cgit v1.2.3 From d00b6e4216bb308ae075d90dfa871c902d765f8d Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Thu, 21 Sep 2023 21:44:37 +0300 Subject: SL-15039 Prune unused preferences #1 List of removed preferences (usused per statistics): AdvanceOutfitSnapshot AnimationDebug AskedAboutCrashReports AudioLevelDoppler AudioLevelRolloff AudioLevelUnderwaterRolloff AudioLevelWind AutoAcceptNewInventory AutoLoadWebProfiles AvatarBacklight AvatarPickerSortOrder AvatarPosFinalOffset AvatarBakedTextureUploadTimeout AvatarBakedLocalTextureUpdateTimeout AnimatedObjectsIgnoreLimits AnimatedObjectsGlobalScale AvatarBoundingBoxComplexity StartUpChannelUUID NearByChatChannelUUID NotificationChannelUUID AlertChannelUUID AssetStorageLogFrequency AvatarInspectorTooltipDelay AllowBottomTrayButtonReordering AvatarRotateThresholdSlow AvatarRotateThresholdFast --- indra/newview/app_settings/settings.xml | 290 ---------------------- indra/newview/llchannelmanager.cpp | 14 +- indra/newview/llcontrolavatar.cpp | 31 +-- indra/newview/llfloaterimnearbychat.cpp | 3 +- indra/newview/llfloaterimnearbychathandler.cpp | 2 +- indra/newview/llfloaterimsession.cpp | 6 +- indra/newview/llfloaternotificationstabbed.cpp | 2 +- indra/newview/llimprocessing.cpp | 25 +- indra/newview/llinspecttoast.cpp | 4 +- indra/newview/llnotificationalerthandler.cpp | 2 +- indra/newview/llpersistentnotificationstorage.cpp | 2 +- indra/newview/llscreenchannel.h | 4 + indra/newview/llscriptfloater.cpp | 2 +- indra/newview/llsyswellwindow.cpp | 4 +- indra/newview/lltextureview.cpp | 4 +- indra/newview/lltoolpie.cpp | 4 +- indra/newview/llvieweraudio.cpp | 19 +- indra/newview/llviewercontrol.cpp | 3 - indra/newview/llviewerdisplay.cpp | 4 +- indra/newview/llviewermessage.cpp | 10 +- indra/newview/llviewerobject.cpp | 17 +- indra/newview/llviewertexlayer.cpp | 6 +- indra/newview/llvoavatar.cpp | 10 +- indra/newview/pipeline.cpp | 2 +- 24 files changed, 76 insertions(+), 394 deletions(-) diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index 816b7b7c92..9d541d98e7 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -137,17 +137,6 @@ Value 1 - AdvanceOutfitSnapshot - - Comment - Display advanced parameter settings in outfit snaphot interface - Persist - 1 - Type - Boolean - Value - 1 - AgentPause Comment @@ -214,17 +203,6 @@ Value 1 - AnimationDebug - - Comment - Show active animations in a bubble above avatars head - Persist - 1 - Type - Boolean - Value - 0 - AppearanceCameraMovement Comment @@ -269,17 +247,6 @@ Value 0 - AskedAboutCrashReports - - Comment - Turns off dialog asking if you want to enable crash reporting - Persist - 1 - Type - Boolean - Value - 0 - AuctionShowFence Comment @@ -302,17 +269,6 @@ Value 0.5 - AudioLevelDoppler - - Comment - Scale of doppler effect on moving audio sources (1.0 = normal, <1.0 = diminished doppler effect, >1.0 = enhanced doppler effect) - Persist - 1 - Type - F32 - Value - 1.0 - AudioLevelMaster Comment @@ -357,28 +313,6 @@ Value 0.3 - AudioLevelRolloff - - Comment - Controls the distance-based dropoff of audio volume (fraction or multiple of default audio rolloff) - Persist - 1 - Type - F32 - Value - 1.0 - - AudioLevelUnderwaterRolloff - - Comment - Controls the distance-based dropoff of audio volume underwater(fraction or multiple of default audio rolloff) - Persist - 1 - Type - F32 - Value - 5.0 - AudioLevelSFX Comment @@ -411,17 +345,6 @@ F32 Value 0.5 - - AudioLevelWind - - Comment - Audio level of wind noise when standing still - Persist - 1 - Type - F32 - Value - 0.5 AudioStreamingMedia @@ -456,17 +379,6 @@ Value 0 - AutoAcceptNewInventory - - Comment - Automatically accept new notecards/textures/landmarks - Persist - 1 - Type - Boolean - Value - 0 - AutoLeveling Comment @@ -478,17 +390,6 @@ Value 1 - AutoLoadWebProfiles - - Comment - Automatically load ALL profile webpages without asking first. - Persist - 1 - Type - Boolean - Value - 0 - AutoLogin Comment @@ -676,17 +577,6 @@ Value 1.0 - AvatarBacklight - - Comment - Add rim lighting to avatar rendering to approximate shininess of skin - Persist - 1 - Type - Boolean - Value - 1 - AvatarFeathering Comment @@ -698,32 +588,6 @@ Value 16.0 - AvatarPickerSortOrder - - Comment - Specifies sort key for textures in avatar picker (+0 = name, +1 = date, +2 = folders always by name, +4 = system folders to top) - Persist - 1 - Type - U32 - Value - 2 - - AvatarPosFinalOffset - - Comment - After-everything-else fixup for avatar position. - Persist - 1 - Type - Vector3 - Value - - 0.0 - 0.0 - 0.0 - - AvatarPickerURL Comment @@ -735,50 +599,6 @@ Value http://lecs-viewer-web-components.s3.amazonaws.com/v3.0/[GRID_LOWERCASE]/avatars.html - AvatarRotateThresholdSlow - - Comment - Angle between avatar facing and camera facing at which avatar turns to face same direction as camera, when moving slowly (degrees) - Persist - 1 - Type - F32 - Value - 60 - - AvatarRotateThresholdFast - - Comment - Angle between avatar facing and camera facing at which avatar turns to face same direction as camera, when moving fast (degrees) - Persist - 1 - Type - F32 - Value - 2 - - AvatarBakedTextureUploadTimeout - - Comment - Specifes the maximum time in seconds to wait before sending your baked textures for avatar appearance. Set to 0 to disable and wait until all baked textures are at highest resolution. - Persist - 1 - Type - U32 - Value - 60 - - AvatarBakedLocalTextureUpdateTimeout - - Comment - Specifes the maximum time in seconds to wait before updating your appearance during appearance mode. - Persist - 1 - Type - U32 - Value - 10 - AvatarPhysics Comment @@ -2275,17 +2095,6 @@ Value 0 - AnimatedObjectsIgnoreLimits - - Comment - Ignore server-enforced limits on animated objects. This is only useful for server testing. - Persist - 1 - Type - Boolean - Value - 0 - AnimatedObjectsAllowLeftClick Comment @@ -2297,17 +2106,6 @@ Value 0 - AnimatedObjectsGlobalScale - - Comment - Temporary testing: allow an extra scale factor to be forced on animated objects. - Persist - 1 - Type - F32 - Value - 1.00 - AnimatedObjectsMaxLegalOffset Comment @@ -2330,17 +2128,6 @@ Value 64.0 - AvatarBoundingBoxComplexity - - Comment - How many aspects to consider for avatar bounding box - Persist - 1 - Type - S32 - Value - 3 - DebugAvatarAppearanceMessage Comment @@ -13333,50 +13120,6 @@ Value 5748decc-f629-461c-9a36-a35a221fe21f - StartUpChannelUUID - - Comment - - Persist - 0 - Type - String - Value - B56AF90D-6684-48E4-B1E4-722D3DEB2CB6 - - NearByChatChannelUUID - - Comment - - Persist - 0 - Type - String - Value - E1158BD6-661C-4981-9DAD-4DCBFF062502 - - NotificationChannelUUID - - Comment - - Persist - 0 - Type - String - Value - AEED3193-8709-4693-8558-7452CCA97AE5 - - AlertChannelUUID - - Comment - - Persist - 0 - Type - String - Value - F3E07BC8-A973-476D-8C7F-F3B7293975D1 - UIImgWhiteUUID Comment @@ -15305,17 +15048,6 @@ Value 0 - AssetStorageLogFrequency - - Comment - Seconds between display of AssetStorage info in log (0 for never) - Persist - 1 - Type - F32 - Value - 60.0 - LogWearableAssetSave Comment @@ -15608,17 +15340,6 @@ Value 0 - AvatarInspectorTooltipDelay - - Comment - Seconds before displaying avatar inspector tooltip - Persist - 1 - Type - F32 - Value - 0.35 - ObjectInspectorTooltipDelay Comment @@ -15827,17 +15548,6 @@ Boolean Value 0 - - AllowBottomTrayButtonReordering - - Comment - Allow user to move and hide bottom tray buttons - Persist - 1 - Type - Boolean - Value - 1 AllowSelectAvatar diff --git a/indra/newview/llchannelmanager.cpp b/indra/newview/llchannelmanager.cpp index 9e7a8ba95c..928508e13a 100644 --- a/indra/newview/llchannelmanager.cpp +++ b/indra/newview/llchannelmanager.cpp @@ -88,7 +88,7 @@ LLScreenChannel* LLChannelManager::createNotificationChannel() { // creating params for a channel LLScreenChannelBase::Params p; - p.id = LLUUID(gSavedSettings.getString("NotificationChannelUUID")); + p.id = NOTIFICATION_CHANNEL_UUID; p.channel_align = CA_RIGHT; p.toast_align = NA_TOP; @@ -108,7 +108,7 @@ void LLChannelManager::onLoginCompleted() if (!channel) continue; // don't calc notifications for Nearby Chat - if(channel->getChannelID() == LLUUID(gSavedSettings.getString("NearByChatChannelUUID"))) + if(channel->getChannelID() == NEARBY_CHAT_CHANNEL_UUID) { continue; } @@ -130,7 +130,7 @@ void LLChannelManager::onLoginCompleted() { // create a channel for the StartUp Toast LLScreenChannelBase::Params p; - p.id = LLUUID(gSavedSettings.getString("StartUpChannelUUID")); + p.id = STARTUP_CHANNEL_UUID; p.channel_align = CA_RIGHT; mStartUpChannel = createChannel(p); @@ -164,7 +164,7 @@ void LLChannelManager::onStartUpToastClose() { mStartUpChannel->setVisible(FALSE); mStartUpChannel->closeStartUpToast(); - removeChannelByID(LLUUID(gSavedSettings.getString("StartUpChannelUUID"))); + removeChannelByID(STARTUP_CHANNEL_UUID); mStartUpChannel = NULL; } @@ -258,12 +258,12 @@ LLNotificationsUI::LLScreenChannel* LLChannelManager::getNotificationScreenChann { LLNotificationsUI::LLScreenChannel* channel = static_cast (LLNotificationsUI::LLChannelManager::getInstance()-> - findChannelByID(LLUUID(gSavedSettings.getString("NotificationChannelUUID")))); + findChannelByID(NOTIFICATION_CHANNEL_UUID)); if (channel == NULL) { - LL_WARNS() << "Can't find screen channel by NotificationChannelUUID" << LL_ENDL; - llassert(!"Can't find screen channel by NotificationChannelUUID"); + LL_WARNS() << "Can't find screen channel by Notification Channel UUID" << LL_ENDL; + llassert(!"Can't find screen channel by Notification Channel UUID"); } return channel; diff --git a/indra/newview/llcontrolavatar.cpp b/indra/newview/llcontrolavatar.cpp index 91031034c6..a71c8bb60f 100644 --- a/indra/newview/llcontrolavatar.cpp +++ b/indra/newview/llcontrolavatar.cpp @@ -99,21 +99,6 @@ LLVOAvatar *LLControlAvatar::getAttachedAvatar() void LLControlAvatar::getNewConstraintFixups(LLVector3& new_pos_fixup, F32& new_scale_fixup) const { - - F32 max_legal_offset = MAX_LEGAL_OFFSET; - if (gSavedSettings.getControl("AnimatedObjectsMaxLegalOffset")) - { - max_legal_offset = gSavedSettings.getF32("AnimatedObjectsMaxLegalOffset"); - } - max_legal_offset = llmax(max_legal_offset,0.f); - - F32 max_legal_size = MAX_LEGAL_SIZE; - if (gSavedSettings.getControl("AnimatedObjectsMaxLegalSize")) - { - max_legal_size = gSavedSettings.getF32("AnimatedObjectsMaxLegalSize"); - } - max_legal_size = llmax(max_legal_size, 1.f); - new_pos_fixup = LLVector3(); new_scale_fixup = 1.0f; LLVector3 vol_pos = mRootVolp->getRenderPosition(); @@ -138,9 +123,9 @@ void LLControlAvatar::getNewConstraintFixups(LLVector3& new_pos_fixup, F32& new_ { LLVector3 pos_box_offset = point_to_box_offset(vol_pos, unshift_extents); F32 offset_dist = pos_box_offset.length(); - if (offset_dist > max_legal_offset && offset_dist > 0.f) + if (offset_dist > MAX_LEGAL_OFFSET && offset_dist > 0.f) { - F32 target_dist = (offset_dist - max_legal_offset); + F32 target_dist = (offset_dist - MAX_LEGAL_OFFSET); new_pos_fixup = (target_dist/offset_dist)*pos_box_offset; } if (new_pos_fixup != mPositionConstraintFixup) @@ -153,11 +138,11 @@ void LLControlAvatar::getNewConstraintFixups(LLVector3& new_pos_fixup, F32& new_ } } - if (box_size/mScaleConstraintFixup > max_legal_size) + if (box_size/mScaleConstraintFixup > MAX_LEGAL_SIZE) { - new_scale_fixup = mScaleConstraintFixup*max_legal_size/box_size; + new_scale_fixup = mScaleConstraintFixup* MAX_LEGAL_SIZE /box_size; LL_DEBUGS("ConstraintFix") << getFullname() << " scale fix, box_size " << box_size << " fixup " - << mScaleConstraintFixup << " max legal " << max_legal_size + << mScaleConstraintFixup << " max legal " << MAX_LEGAL_SIZE << " -> new scale " << new_scale_fixup << LL_ENDL; } } @@ -202,8 +187,7 @@ void LLControlAvatar::matchVolumeTransform() mRoot->setWorldRotation(obj_rot * joint_rot); setRotation(mRoot->getRotation()); - F32 global_scale = gSavedSettings.getF32("AnimatedObjectsGlobalScale"); - setGlobalScale(global_scale * mScaleConstraintFixup); + setGlobalScale(mScaleConstraintFixup); } else { @@ -253,8 +237,7 @@ void LLControlAvatar::matchVolumeTransform() } mRoot->setPosition(vol_pos + mPositionConstraintFixup); - F32 global_scale = gSavedSettings.getF32("AnimatedObjectsGlobalScale"); - setGlobalScale(global_scale * mScaleConstraintFixup); + setGlobalScale(mScaleConstraintFixup); } } } diff --git a/indra/newview/llfloaterimnearbychat.cpp b/indra/newview/llfloaterimnearbychat.cpp index bb4cc9bca3..80dd1c8566 100644 --- a/indra/newview/llfloaterimnearbychat.cpp +++ b/indra/newview/llfloaterimnearbychat.cpp @@ -260,7 +260,8 @@ void LLFloaterIMNearbyChat::loadHistory() void LLFloaterIMNearbyChat::removeScreenChat() { - LLNotificationsUI::LLScreenChannelBase* chat_channel = LLNotificationsUI::LLChannelManager::getInstance()->findChannelByID(LLUUID(gSavedSettings.getString("NearByChatChannelUUID"))); + LLNotificationsUI::LLScreenChannelBase* chat_channel = LLNotificationsUI::LLChannelManager::getInstance()->findChannelByID( + LLNotificationsUI::NEARBY_CHAT_CHANNEL_UUID); if(chat_channel) { chat_channel->removeToastsFromChannel(); diff --git a/indra/newview/llfloaterimnearbychathandler.cpp b/indra/newview/llfloaterimnearbychathandler.cpp index 4cd91c53d8..be731c8043 100644 --- a/indra/newview/llfloaterimnearbychathandler.cpp +++ b/indra/newview/llfloaterimnearbychathandler.cpp @@ -459,7 +459,7 @@ LLFloaterIMNearbyChatHandler::LLFloaterIMNearbyChatHandler() { // Getting a Channel for our notifications LLFloaterIMNearbyChatScreenChannel::Params p; - p.id = LLUUID(gSavedSettings.getString("NearByChatChannelUUID")); + p.id = NEARBY_CHAT_CHANNEL_UUID; LLFloaterIMNearbyChatScreenChannel* channel = new LLFloaterIMNearbyChatScreenChannel(p); LLFloaterIMNearbyChatScreenChannel::create_toast_panel_callback_t callback = createToastPanel; diff --git a/indra/newview/llfloaterimsession.cpp b/indra/newview/llfloaterimsession.cpp index ee9dc35283..5ac7b4a654 100644 --- a/indra/newview/llfloaterimsession.cpp +++ b/indra/newview/llfloaterimsession.cpp @@ -651,7 +651,7 @@ void LLFloaterIMSession::setDocked(bool docked, bool pop_on_undock) // update notification channel state LLNotificationsUI::LLScreenChannel* channel = static_cast (LLNotificationsUI::LLChannelManager::getInstance()-> - findChannelByID(LLUUID(gSavedSettings.getString("NotificationChannelUUID")))); + findChannelByID(LLNotificationsUI::NOTIFICATION_CHANNEL_UUID)); if(!isChatMultiTab()) { @@ -687,7 +687,7 @@ void LLFloaterIMSession::setVisible(BOOL visible) { LLNotificationsUI::LLScreenChannel* channel = static_cast (LLNotificationsUI::LLChannelManager::getInstance()-> - findChannelByID(LLUUID(gSavedSettings.getString("NotificationChannelUUID")))); + findChannelByID(LLNotificationsUI::NOTIFICATION_CHANNEL_UUID)); LLFloaterIMSessionTab::setVisible(visible); @@ -865,7 +865,7 @@ void LLFloaterIMSession::updateMessages() // remove embedded notification from channel LLNotificationsUI::LLScreenChannel* channel = static_cast (LLNotificationsUI::LLChannelManager::getInstance()-> - findChannelByID(LLUUID(gSavedSettings.getString("NotificationChannelUUID")))); + findChannelByID(LLNotificationsUI::NOTIFICATION_CHANNEL_UUID)); if (getVisible()) { // toast will be automatically closed since it is not storable toast diff --git a/indra/newview/llfloaternotificationstabbed.cpp b/indra/newview/llfloaternotificationstabbed.cpp index d1679fd936..2ff6c5618c 100644 --- a/indra/newview/llfloaternotificationstabbed.cpp +++ b/indra/newview/llfloaternotificationstabbed.cpp @@ -154,7 +154,7 @@ LLPanel * LLFloaterNotificationsTabbed::findItemByID(const LLUUID& id, std::stri void LLFloaterNotificationsTabbed::initChannel() { LLNotificationsUI::LLScreenChannelBase* channel = LLNotificationsUI::LLChannelManager::getInstance()->findChannelByID( - LLUUID(gSavedSettings.getString("NotificationChannelUUID"))); + LLNotificationsUI::NOTIFICATION_CHANNEL_UUID); mChannel = dynamic_cast(channel); if(NULL == mChannel) { diff --git a/indra/newview/llimprocessing.cpp b/indra/newview/llimprocessing.cpp index 948793681d..a1a82fef7b 100644 --- a/indra/newview/llimprocessing.cpp +++ b/indra/newview/llimprocessing.cpp @@ -189,18 +189,6 @@ void inventory_offer_handler(LLOfferInfo* info) return; } - bool bAutoAccept(false); - // Avoid the Accept/Discard dialog if the user so desires. JC - if (gSavedSettings.getBOOL("AutoAcceptNewInventory") - && (info->mType == LLAssetType::AT_NOTECARD - || info->mType == LLAssetType::AT_LANDMARK - || info->mType == LLAssetType::AT_TEXTURE)) - { - // For certain types, just accept the items into the inventory, - // and possibly open them on receipt depending upon "ShowNewInventory". - bAutoAccept = true; - } - // Strip any SLURL from the message display. (DEV-2754) std::string msg = info->mDesc; int indx = msg.find(" ( http://slurl.com/secondlife/"); @@ -266,7 +254,7 @@ void inventory_offer_handler(LLOfferInfo* info) LLNotification::Params p; // Object -> Agent Inventory Offer - if (info->mFromObject && !bAutoAccept) + if (info->mFromObject) { // Inventory Slurls don't currently work for non agent transfers, so only display the object name. args["ITEM_SLURL"] = msg; @@ -312,13 +300,10 @@ void inventory_offer_handler(LLOfferInfo* info) send_do_not_disturb_message(gMessageSystem, info->mFromID); } - if (!bAutoAccept) // if we auto accept, do not pester the user - { - // Inform user that there is a script floater via toast system - payload["give_inventory_notification"] = TRUE; - p.payload = payload; - LLPostponedNotification::add(p, info->mFromID, false); - } + // Inform user that there is a script floater via toast system + payload["give_inventory_notification"] = TRUE; + p.payload = payload; + LLPostponedNotification::add(p, info->mFromID, false); } LLFirstUse::newInventory(); diff --git a/indra/newview/llinspecttoast.cpp b/indra/newview/llinspecttoast.cpp index 6f93a78ca6..21cdde0bea 100644 --- a/indra/newview/llinspecttoast.cpp +++ b/indra/newview/llinspecttoast.cpp @@ -60,8 +60,8 @@ private: LLInspectToast::LLInspectToast(const LLSD& notification_id) : LLInspect(LLSD()), mPanel(NULL) { - LLScreenChannelBase* channel = LLChannelManager::getInstance()->findChannelByID( - LLUUID(gSavedSettings.getString("NotificationChannelUUID"))); + LLScreenChannelBase* channel = LLChannelManager::getInstance()->findChannelByID( + LLNotificationsUI::NOTIFICATION_CHANNEL_UUID); mScreenChannel = dynamic_cast(channel); if(NULL == mScreenChannel) { diff --git a/indra/newview/llnotificationalerthandler.cpp b/indra/newview/llnotificationalerthandler.cpp index 90b9cdc133..df8ab84663 100644 --- a/indra/newview/llnotificationalerthandler.cpp +++ b/indra/newview/llnotificationalerthandler.cpp @@ -46,7 +46,7 @@ LLAlertHandler::LLAlertHandler(const std::string& name, const std::string& notif mIsModal(is_modal) { LLScreenChannelBase::Params p; - p.id = LLUUID(gSavedSettings.getString("AlertChannelUUID")); + p.id = ALERT_CHANNEL_UUID; p.display_toasts_always = true; p.toast_align = NA_CENTRE; p.channel_align = CA_CENTRE; diff --git a/indra/newview/llpersistentnotificationstorage.cpp b/indra/newview/llpersistentnotificationstorage.cpp index 9bf771db8a..ec537e216b 100644 --- a/indra/newview/llpersistentnotificationstorage.cpp +++ b/indra/newview/llpersistentnotificationstorage.cpp @@ -115,7 +115,7 @@ void LLPersistentNotificationStorage::loadNotifications() using namespace LLNotificationsUI; LLScreenChannel* notification_channel = dynamic_cast(LLChannelManager::getInstance()-> - findChannelByID(LLUUID(gSavedSettings.getString("NotificationChannelUUID")))); + findChannelByID(LLNotificationsUI::NOTIFICATION_CHANNEL_UUID)); LLNotifications& instance = LLNotifications::instance(); S32 processed_notifications = 0; diff --git a/indra/newview/llscreenchannel.h b/indra/newview/llscreenchannel.h index e5f4807ab7..d881952419 100644 --- a/indra/newview/llscreenchannel.h +++ b/indra/newview/llscreenchannel.h @@ -34,6 +34,10 @@ namespace LLNotificationsUI { + const LLUUID ALERT_CHANNEL_UUID("F3E07BC8-A973-476D-8C7F-F3B7293975D1"); + const LLUUID NOTIFICATION_CHANNEL_UUID("AEED3193-8709-4693-8558-7452CCA97AE5"); + const LLUUID NEARBY_CHAT_CHANNEL_UUID("E1158BD6-661C-4981-9DAD-4DCBFF062502"); + const LLUUID STARTUP_CHANNEL_UUID("B56AF90D-6684-48E4-B1E4-722D3DEB2CB6"); typedef enum e_notification_toast_alignment { diff --git a/indra/newview/llscriptfloater.cpp b/indra/newview/llscriptfloater.cpp index 6a27ff3047..66ee016191 100644 --- a/indra/newview/llscriptfloater.cpp +++ b/indra/newview/llscriptfloater.cpp @@ -335,7 +335,7 @@ void LLScriptFloater::hideToastsIfNeeded() // find channel LLScreenChannel* channel = dynamic_cast(LLChannelManager::getInstance()->findChannelByID( - LLUUID(gSavedSettings.getString("NotificationChannelUUID")))); + LLNotificationsUI::NOTIFICATION_CHANNEL_UUID)); // update notification channel state if(channel) { diff --git a/indra/newview/llsyswellwindow.cpp b/indra/newview/llsyswellwindow.cpp index 8f64cff47c..db6d822186 100644 --- a/indra/newview/llsyswellwindow.cpp +++ b/indra/newview/llsyswellwindow.cpp @@ -127,8 +127,8 @@ void LLSysWellWindow::removeItemByID(const LLUUID& id) //--------------------------------------------------------------------------------- void LLSysWellWindow::initChannel() { - LLNotificationsUI::LLScreenChannelBase* channel = LLNotificationsUI::LLChannelManager::getInstance()->findChannelByID( - LLUUID(gSavedSettings.getString("NotificationChannelUUID"))); + LLNotificationsUI::LLScreenChannelBase* channel = LLNotificationsUI::LLChannelManager::getInstance()->findChannelByID( + LLNotificationsUI::NOTIFICATION_CHANNEL_UUID); mChannel = dynamic_cast(channel); if(NULL == mChannel) { diff --git a/indra/newview/lltextureview.cpp b/indra/newview/lltextureview.cpp index 84b61fc612..161ca12b55 100644 --- a/indra/newview/lltextureview.cpp +++ b/indra/newview/lltextureview.cpp @@ -439,14 +439,12 @@ void LLAvatarTexBar::draw() text_color, LLFontGL::LEFT, LLFontGL::TOP); //, LLFontGL::BOLD, LLFontGL::DROP_SHADOW_SOFT); line_num++; } - const U32 texture_timeout = gSavedSettings.getU32("AvatarBakedTextureUploadTimeout"); const U32 override_tex_discard_level = gSavedSettings.getU32("TextureDiscardLevel"); LLColor4 header_color(1.f, 1.f, 1.f, 0.9f); - const std::string texture_timeout_str = texture_timeout ? llformat("%d",texture_timeout) : "Disabled"; const std::string override_tex_discard_level_str = override_tex_discard_level ? llformat("%d",override_tex_discard_level) : "Disabled"; - std::string header_text = llformat("[ Timeout('AvatarBakedTextureUploadTimeout'):%s ] [ LOD_Override('TextureDiscardLevel'):%s ]", texture_timeout_str.c_str(), override_tex_discard_level_str.c_str()); + std::string header_text = llformat("[ Timeout:60 ] [ LOD_Override('TextureDiscardLevel'):%s ]", override_tex_discard_level_str.c_str()); LLFontGL::getFontMonospace()->renderUTF8(header_text, 0, l_offset, v_offset + line_height*line_num, header_color, LLFontGL::LEFT, LLFontGL::TOP); //, LLFontGL::BOLD, LLFontGL::DROP_SHADOW_SOFT); line_num++; diff --git a/indra/newview/lltoolpie.cpp b/indra/newview/lltoolpie.cpp index 58011bbde2..1ea5983466 100644 --- a/indra/newview/lltoolpie.cpp +++ b/indra/newview/lltoolpie.cpp @@ -1110,6 +1110,8 @@ BOOL LLToolPie::handleTooltipObject( LLViewerObject* hover_object, std::string l final_name = LLTrans::getString("TooltipPerson");; } + const F32 INSPECTOR_TOOLTIP_DELAY = 0.35f; + LLInspector::Params p; p.fillFrom(LLUICtrlFactory::instance().getDefaultParams()); p.message(final_name); @@ -1117,7 +1119,7 @@ BOOL LLToolPie::handleTooltipObject( LLViewerObject* hover_object, std::string l p.click_callback(boost::bind(showAvatarInspector, hover_object->getID())); p.visible_time_near(6.f); p.visible_time_far(3.f); - p.delay_time(gSavedSettings.getF32("AvatarInspectorTooltipDelay")); + p.delay_time(INSPECTOR_TOOLTIP_DELAY); p.wrap(false); LLToolTipMgr::instance().show(p); diff --git a/indra/newview/llvieweraudio.cpp b/indra/newview/llvieweraudio.cpp index 6a0edbecb1..134fe0885e 100644 --- a/indra/newview/llvieweraudio.cpp +++ b/indra/newview/llvieweraudio.cpp @@ -418,12 +418,19 @@ void audio_update_volume(bool force_update) gAudiop->setMasterGain ( master_volume ); - gAudiop->setDopplerFactor(gSavedSettings.getF32("AudioLevelDoppler")); + const F32 AUDIO_LEVEL_DOPPLER = 1.f; + gAudiop->setDopplerFactor(AUDIO_LEVEL_DOPPLER); - if(!LLViewerCamera::getInstance()->cameraUnderWater()) - gAudiop->setRolloffFactor(gSavedSettings.getF32("AudioLevelRolloff")); + if(!LLViewerCamera::getInstance()->cameraUnderWater()) + { + const F32 AUDIO_LEVEL_ROLLOFF = 1.f; + gAudiop->setRolloffFactor(AUDIO_LEVEL_ROLLOFF); + } else - gAudiop->setRolloffFactor(gSavedSettings.getF32("AudioLevelUnderwaterRolloff")); + { + const F32 AUDIO_LEVEL_UNDERWATER_ROLLOFF = 5.f; + gAudiop->setRolloffFactor(AUDIO_LEVEL_UNDERWATER_ROLLOFF); + } gAudiop->setMuted(mute_audio || progress_view_visible); @@ -532,8 +539,8 @@ void audio_update_wind(bool force_update) // whereas steady-state avatar walk velocity is only 3.2 m/s. // Without this the world feels desolate on first login when you are // standing still. - static LLUICachedControl wind_level("AudioLevelWind", 0.5f); - LLVector3 scaled_wind_vec = gWindVec * wind_level; + const F32 WIND_LEVEL = 0.5f; + LLVector3 scaled_wind_vec = gWindVec * WIND_LEVEL; // Mix in the avatar's motion, subtract because when you walk north, // the apparent wind moves south. diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index 50d48987ed..668214a47c 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -815,9 +815,6 @@ void settings_setup_listeners() setting_setup_signal_listener(gSavedSettings, "AudioLevelMusic", handleAudioVolumeChanged); setting_setup_signal_listener(gSavedSettings, "AudioLevelMedia", handleAudioVolumeChanged); setting_setup_signal_listener(gSavedSettings, "AudioLevelVoice", handleAudioVolumeChanged); - setting_setup_signal_listener(gSavedSettings, "AudioLevelDoppler", handleAudioVolumeChanged); - setting_setup_signal_listener(gSavedSettings, "AudioLevelRolloff", handleAudioVolumeChanged); - setting_setup_signal_listener(gSavedSettings, "AudioLevelUnderwaterRolloff", handleAudioVolumeChanged); setting_setup_signal_listener(gSavedSettings, "MuteAudio", handleAudioVolumeChanged); setting_setup_signal_listener(gSavedSettings, "MuteMusic", handleAudioVolumeChanged); setting_setup_signal_listener(gSavedSettings, "MuteMedia", handleAudioVolumeChanged); diff --git a/indra/newview/llviewerdisplay.cpp b/indra/newview/llviewerdisplay.cpp index b40cf4acec..206304dbf5 100644 --- a/indra/newview/llviewerdisplay.cpp +++ b/indra/newview/llviewerdisplay.cpp @@ -228,8 +228,8 @@ void display_stats() LLMemory::logMemoryInfo(TRUE) ; gRecentMemoryTime.reset(); } - F32 asset_storage_log_freq = gSavedSettings.getF32("AssetStorageLogFrequency"); - if (asset_storage_log_freq > 0.f && gAssetStorageLogTime.getElapsedTimeF32() >= asset_storage_log_freq) + const F32 ASSET_STORAGE_LOG_FREQUENCY = 60.f; + if (gAssetStorageLogTime.getElapsedTimeF32() >= ASSET_STORAGE_LOG_FREQUENCY) { LL_PROFILE_ZONE_NAMED_CATEGORY_DISPLAY("DS - Asset Storage"); gAssetStorageLogTime.reset(); diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp index 7421bba733..df5e3021b1 100644 --- a/indra/newview/llviewermessage.cpp +++ b/indra/newview/llviewermessage.cpp @@ -1616,8 +1616,9 @@ void inventory_offer_mute_callback(const LLUUID& blocked_id, const LLUUID& blocked_id; }; - LLNotificationsUI::LLChannelManager::getInstance()->killToastsFromChannel(LLUUID( - gSavedSettings.getString("NotificationChannelUUID")), OfferMatcher(blocked_id)); + LLNotificationsUI::LLChannelManager::getInstance()->killToastsFromChannel( + LLNotificationsUI::NOTIFICATION_CHANNEL_UUID, + OfferMatcher(blocked_id)); } @@ -5737,8 +5738,9 @@ void script_question_mute(const LLUUID& task_id, const std::string& object_name) const LLUUID& blocked_id; }; - LLNotificationsUI::LLChannelManager::getInstance()->killToastsFromChannel(LLUUID( - gSavedSettings.getString("NotificationChannelUUID")), OfferMatcher(task_id)); + LLNotificationsUI::LLChannelManager::getInstance()->killToastsFromChannel( + LLNotificationsUI::NOTIFICATION_CHANNEL_UUID, + OfferMatcher(task_id)); } static LLNotificationFunctorRegistration script_question_cb_reg_1("ScriptQuestion", script_question_cb); diff --git a/indra/newview/llviewerobject.cpp b/indra/newview/llviewerobject.cpp index f47f0b4572..55a6d19103 100644 --- a/indra/newview/llviewerobject.cpp +++ b/indra/newview/llviewerobject.cpp @@ -3867,20 +3867,13 @@ F32 LLViewerObject::recursiveGetEstTrianglesMax() const S32 LLViewerObject::getAnimatedObjectMaxTris() const { S32 max_tris = 0; - if (gSavedSettings.getBOOL("AnimatedObjectsIgnoreLimits")) + if (gAgent.getRegion()) { - max_tris = S32_MAX; - } - else - { - if (gAgent.getRegion()) + LLSD features; + gAgent.getRegion()->getSimulatorFeatures(features); + if (features.has("AnimatedObjects")) { - LLSD features; - gAgent.getRegion()->getSimulatorFeatures(features); - if (features.has("AnimatedObjects")) - { - max_tris = features["AnimatedObjects"]["AnimatedObjectMaxTris"].asInteger(); - } + max_tris = features["AnimatedObjects"]["AnimatedObjectMaxTris"].asInteger(); } } return max_tris; diff --git a/indra/newview/llviewertexlayer.cpp b/indra/newview/llviewertexlayer.cpp index 4c2fbcf837..ae8163beec 100644 --- a/indra/newview/llviewertexlayer.cpp +++ b/indra/newview/llviewertexlayer.cpp @@ -186,11 +186,11 @@ BOOL LLViewerTexLayerSetBuffer::isReadyToUpdate() const // Update if we've hit a timeout. Unlike for uploads, we can make this timeout fairly small // since render unnecessarily doesn't cost much. - const U32 texture_timeout = gSavedSettings.getU32("AvatarBakedLocalTextureUpdateTimeout"); - if (texture_timeout != 0) + const U32 TEXTURE_TIMEOUT = 10; + if (TEXTURE_TIMEOUT != 0) { // If we hit our timeout and have textures available at even lower resolution, then update. - const BOOL is_update_textures_timeout = mNeedsUpdateTimer.getElapsedTimeF32() >= texture_timeout; + const BOOL is_update_textures_timeout = mNeedsUpdateTimer.getElapsedTimeF32() >= TEXTURE_TIMEOUT; const BOOL has_lower_lod = getViewerTexLayerSet()->isLocalTextureDataAvailable(); if (has_lower_lod && is_update_textures_timeout) return TRUE; } diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index 305c489cc8..b5dc1dee94 100644 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -1351,8 +1351,8 @@ void LLVOAvatar::calculateSpatialExtents(LLVector4a& newMin, LLVector4a& newMax) { LL_PROFILE_ZONE_SCOPED_CATEGORY_AVATAR; - static LLCachedControl box_detail_cache(gSavedSettings, "AvatarBoundingBoxComplexity"); - S32 box_detail = box_detail_cache; + const S32 BOX_DETAIL_DEFAULT = 3; + S32 box_detail = BOX_DETAIL_DEFAULT; if (getOverallAppearance() != AOA_NORMAL) { if (isControlAvatar()) @@ -4248,10 +4248,10 @@ void LLVOAvatar::updateOrientation(LLAgent& agent, F32 speed, F32 delta_time) LLVector3 pelvisDir( mRoot->getWorldMatrix().getFwdRow4().mV ); - static LLCachedControl s_pelvis_rot_threshold_slow(gSavedSettings, "AvatarRotateThresholdSlow", 60.0); - static LLCachedControl s_pelvis_rot_threshold_fast(gSavedSettings, "AvatarRotateThresholdFast", 2.0); + const F32 AVATAR_PELVIS_ROTATE_THRESHOLD_SLOW = 60.0f; + const F32 AVATAR_PELVIS_ROTATE_THRESHOLD_FAST = 2.0f; - F32 pelvis_rot_threshold = clamp_rescale(speed, 0.1f, 1.0f, s_pelvis_rot_threshold_slow, s_pelvis_rot_threshold_fast); + F32 pelvis_rot_threshold = clamp_rescale(speed, 0.1f, 1.0f, AVATAR_PELVIS_ROTATE_THRESHOLD_SLOW, AVATAR_PELVIS_ROTATE_THRESHOLD_FAST); if (self_in_mouselook) { diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index bbff6c889f..188914f0d5 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -5891,7 +5891,7 @@ void LLPipeline::setupAvatarLights(bool for_edit) light->setSpotExponent(0.f); light->setSpotCutoff(180.f); } - else if (gAvatarBacklight) // Always true (unless overridden in a devs .ini) + else if (gAvatarBacklight) { LLVector3 light_dir = sun_up ? LLVector3(mSunDir) : LLVector3(mMoonDir); LLVector3 opposite_pos = -light_dir; -- cgit v1.2.3 From a53d111cfab7b030a4bd603ba163b7cb66f4a35d Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Thu, 21 Sep 2023 23:51:03 +0300 Subject: SL-15039 Prune unused preferences #2 List of removed preferences (usused per statistics): BottomPanelNew BrowserHomePage BlockSomeAvatarAppearanceVisualParams ButtonHPad ButtonHeight ButtonHeightSmall CacheNumberOfRegionsForObjects ChatBarStealsFocus ChatLoadGroupTimeout ChatPersistTime ChatShowTimestamps ContextConeInAlpha ContextConeOutAlpha ContextConeFadeTime ConversationHistoryPageSize ContactsTornOff CurlMaximumNumberOfHandles CurlUseMultipleThreads CustomServer DebugShowPrivateMem --- indra/llui/llbutton.cpp | 12 +- indra/llui/llfloater.h | 4 + indra/llui/llmenugl.cpp | 4 +- indra/llxml/llcontrol.cpp | 4 - indra/newview/app_settings/settings.xml | 298 ------------------------- indra/newview/llappviewer.cpp | 10 +- indra/newview/llfloateravatarpicker.cpp | 10 +- indra/newview/llfloatercolorpicker.cpp | 10 +- indra/newview/llfloaterconversationpreview.cpp | 3 +- indra/newview/llfloaterexperiencepicker.cpp | 9 +- indra/newview/llscreenchannel.cpp | 3 +- indra/newview/llsetkeybinddialog.cpp | 9 +- indra/newview/llstartup.cpp | 4 +- indra/newview/lltoolpie.cpp | 4 +- indra/newview/llviewercontrol.cpp | 14 -- indra/newview/llviewerwindow.cpp | 4 +- indra/newview/llvoavatar.cpp | 13 +- 17 files changed, 39 insertions(+), 376 deletions(-) diff --git a/indra/llui/llbutton.cpp b/indra/llui/llbutton.cpp index 3354cb2db3..fe9908a475 100644 --- a/indra/llui/llbutton.cpp +++ b/indra/llui/llbutton.cpp @@ -58,10 +58,10 @@ static LLDefaultChildRegistry::Register r("button"); template class LLButton* LLView::getChild( const std::string& name, BOOL recurse) const; -// globals loaded from settings.xml -S32 LLBUTTON_H_PAD = 0; -S32 BTN_HEIGHT_SMALL= 0; -S32 BTN_HEIGHT = 0; +// globals +S32 LLBUTTON_H_PAD = 4; +S32 BTN_HEIGHT_SMALL= 23; +S32 BTN_HEIGHT = 23; LLButton::Params::Params() : label_selected("label_selected"), // requires is_toggle true @@ -91,8 +91,8 @@ LLButton::Params::Params() image_overlay_disabled_color("image_overlay_disabled_color", LLColor4::white % 0.3f), image_overlay_selected_color("image_overlay_selected_color", LLColor4::white), flash_color("flash_color"), - pad_right("pad_right", LLUI::getInstance()->mSettingGroups["config"]->getS32("ButtonHPad")), - pad_left("pad_left", LLUI::getInstance()->mSettingGroups["config"]->getS32("ButtonHPad")), + pad_right("pad_right", LLBUTTON_H_PAD), + pad_left("pad_left", LLBUTTON_H_PAD), pad_bottom("pad_bottom"), click_callback("click_callback"), mouse_down_callback("mouse_down_callback"), diff --git a/indra/llui/llfloater.h b/indra/llui/llfloater.h index 668cd208a9..7840611ce1 100644 --- a/indra/llui/llfloater.h +++ b/indra/llui/llfloater.h @@ -61,6 +61,10 @@ const BOOL CLOSE_NO = FALSE; const BOOL ADJUST_VERTICAL_YES = TRUE; const BOOL ADJUST_VERTICAL_NO = FALSE; +const F32 CONTEXT_CONE_IN_ALPHA = 0.f; +const F32 CONTEXT_CONE_OUT_ALPHA = 1.f; +const F32 CONTEXT_CONE_FADE_TIME = .08f; + namespace LLFloaterEnums { enum EOpenPositioning diff --git a/indra/llui/llmenugl.cpp b/indra/llui/llmenugl.cpp index 16c27da56a..32c5ceb20e 100644 --- a/indra/llui/llmenugl.cpp +++ b/indra/llui/llmenugl.cpp @@ -66,8 +66,8 @@ LLMenuHolderGL *LLMenuGL::sMenuContainer = NULL; view_listener_t::listener_map_t view_listener_t::sListeners; -S32 MENU_BAR_HEIGHT = 0; -S32 MENU_BAR_WIDTH = 0; +S32 MENU_BAR_HEIGHT = 18; +S32 MENU_BAR_WIDTH = 410; ///============================================================================ /// Local function declarations, constants, enums, and typedefs diff --git a/indra/llxml/llcontrol.cpp b/indra/llxml/llcontrol.cpp index 2960ecf829..27e17ec4bb 100644 --- a/indra/llxml/llcontrol.cpp +++ b/indra/llxml/llcontrol.cpp @@ -1497,8 +1497,6 @@ DECL_LLCC(LLColor4U, LLColor4U(255, 200, 100, 255)); LLSD test_llsd = LLSD()["testing1"] = LLSD()["testing2"]; DECL_LLCC(LLSD, test_llsd); -static LLCachedControl test_BrowserHomePage("BrowserHomePage", "hahahahahha", "Not the real comment"); - void test_cached_control() { #define TEST_LLCC(T, V) if((T)mySetting_##T != V) LL_ERRS() << "Fail "#T << LL_ENDL @@ -1515,8 +1513,6 @@ void test_cached_control() TEST_LLCC(LLColor3, LLColor3(1.0f, 0.f, 0.5f)); TEST_LLCC(LLColor4U, LLColor4U(255, 200, 100, 255)); //There's no LLSD comparsion for LLCC yet. TEST_LLCC(LLSD, test_llsd); - - if((std::string)test_BrowserHomePage != "http://www.secondlife.com") LL_ERRS() << "Fail BrowserHomePage" << LL_ENDL; } #endif // TEST_CACHED_CONTROL diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index 9d541d98e7..7a8c1abd7a 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -632,28 +632,6 @@ Value 40 - BottomPanelNew - - Comment - Enable the new bottom panel - Persist - 1 - Type - Boolean - Value - 0 - - BrowserHomePage - - Comment - [NOT USED] - Persist - 1 - Type - String - Value - http://www.secondlife.com - BrowserIgnoreSSLCertErrors Comment @@ -687,17 +665,6 @@ Value 0 - BlockSomeAvatarAppearanceVisualParams - - Comment - Drop around 50% of VisualParam occurances in appearance messages (for simulating Ruth) - Persist - 1 - Type - Boolean - Value - 0 - BrowserProxyAddress Comment @@ -1127,39 +1094,6 @@ Value 1 - ButtonHPad - - Comment - Default horizontal spacing between buttons (pixels) - Persist - 1 - Type - S32 - Value - 4 - - ButtonHeight - - Comment - Default height for normal buttons (pixels) - Persist - 1 - Type - S32 - Value - 23 - - ButtonHeightSmall - - Comment - Default height for small buttons (pixels) - Persist - 1 - Type - S32 - Value - 23 - EnableDiskCacheDebugInfo Comment @@ -1215,17 +1149,6 @@ Value - CacheNumberOfRegionsForObjects - - Comment - Controls number of regions to be cached for objects. - Persist - 1 - Type - U32 - Value - 128 - CacheSize Comment @@ -1510,17 +1433,6 @@ Value 1 - ChatBarStealsFocus - - Comment - Whenever keyboard focus is removed from the UI, and the chat bar is visible, the chat bar takes focus - Persist - 1 - Type - Boolean - Value - 1 - LetterKeysFocusChatBar Comment @@ -1587,17 +1499,6 @@ Value 100 - ChatLoadGroupTimeout - - Comment - Time we give the server to send group participants before we hit the server for group info (seconds) - Persist - 1 - Type - F32 - Value - 10.0 - ChatOnlineNotification Comment @@ -1609,28 +1510,6 @@ Value 1 - ChatPersistTime - - Comment - Time for which chat stays visible in console (seconds) - Persist - 1 - Type - F32 - Value - 20.0 - - ChatShowTimestamps - - Comment - Show timestamps in chat - Persist - 1 - Type - Boolean - Value - 1 - CheesyBeacon Comment @@ -1653,50 +1532,6 @@ Value - ContextConeInAlpha - - Comment - Cone In Alpha - Persist - 0 - Type - F32 - Value - 0.0 - - ContextConeOutAlpha - - Comment - Cone Out Alpha - Persist - 0 - Type - F32 - Value - 1.0 - - ContextConeFadeTime - - Comment - Cone Fade Time - Persist - 0 - Type - F32 - Value - .08 - - ConversationHistoryPageSize - - Comment - Chat history of conversation opened from call log is displayed by pages. So this is number of entries per page. - Persist - 1 - Type - S32 - Value - 100 - ConversationSortOrder Comment @@ -1875,17 +1710,6 @@ Value 40 - ContactsTornOff - - Comment - Show contacts window separately from Communicate window. - Persist - 1 - Type - Boolean - Value - 0 - CookiesEnabled Comment @@ -2007,17 +1831,6 @@ Value 0 - CurlMaximumNumberOfHandles - - Comment - Maximum number of handles curl can use (requires restart) - Persist - 1 - Type - S32 - Value - 256 - CurlRequestTimeOut Comment @@ -2028,17 +1841,6 @@ F32 Value 120.0 - - CurlUseMultipleThreads - - Comment - Use background threads for executing curl_multi_perform (requires restart) - Persist - 1 - Type - Boolean - Value - 1 Cursor3D @@ -2062,17 +1864,6 @@ Value - CustomServer - - Comment - Specifies IP address or hostname of grid to which you connect - Persist - 1 - Type - String - Value - - DebugAnimatedObjects Comment @@ -2315,18 +2106,6 @@ Value 0 - DebugShowPrivateMem - - - Comment - (Deprecated) Show Private Mem Info - Persist - 1 - Type - Boolean - Value - 0 - DebugShowRenderInfo Comment @@ -3317,28 +3096,6 @@ Value 1 - ClickActionBuyEnabled - - Comment - Enable click to buy actions in tool pie menu - Persist - 1 - Type - Boolean - Value - 1 - - ClickActionPayEnabled - - Comment - Enable click to pay actions in tool pie menu - Persist - 1 - Type - Boolean - Value - 1 - DoubleClickAutoPilot Comment @@ -6476,28 +6233,6 @@ Value 0.25 - MenuBarHeight - - Comment - - Persist - 0 - Type - S32 - Value - 18 - - MenuBarWidth - - Comment - - Persist - 0 - Type - S32 - Value - 410 - MePanelOpened Comment @@ -7151,17 +6886,6 @@ Value 90 - ChannelBottomPanelMargin - - Comment - Space from a lower toast to the Bottom Tray - Persist - 1 - Type - S32 - Value - 35 - NotificationChannelRightMargin Comment @@ -7839,17 +7563,6 @@ F32 Value 6.0 - - ClothingLoadingDelay - - Comment - Time to wait for avatar appearance to resolve before showing world (seconds) - Persist - 1 - Type - F32 - Value - 10.0 PreferredMaturity @@ -12790,17 +12503,6 @@ Value - BingTranslateAPIKey - - Comment - (Deprecated) Bing AppID to use with the Microsoft Translator API - Persist - 1 - Type - String - Value - - AzureTranslateAPIKey Comment diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 31a87bbde1..cb5d8e8241 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -528,13 +528,6 @@ bool create_text_segment_icon_from_url_match(LLUrlMatch* match,LLTextBase* base) // or for things that are performance critical. JC static void settings_to_globals() { - LLBUTTON_H_PAD = gSavedSettings.getS32("ButtonHPad"); - BTN_HEIGHT_SMALL = gSavedSettings.getS32("ButtonHeightSmall"); - BTN_HEIGHT = gSavedSettings.getS32("ButtonHeight"); - - MENU_BAR_HEIGHT = gSavedSettings.getS32("MenuBarHeight"); - MENU_BAR_WIDTH = gSavedSettings.getS32("MenuBarWidth"); - LLSurface::setTextureSize(gSavedSettings.getU32("RegionTextureSize")); LLRender::sGLCoreProfile = gSavedSettings.getBOOL("RenderGLContextCoreProfile"); @@ -4271,7 +4264,8 @@ bool LLAppViewer::initCache() LLAppViewer::getTextureCache()->initCache(LL_PATH_CACHE, texture_cache_size, texture_cache_mismatch); - LLVOCache::getInstance()->initCache(LL_PATH_CACHE, gSavedSettings.getU32("CacheNumberOfRegionsForObjects"), getObjectCacheVersion()); + const U32 CACHE_NUMBER_OF_REGIONS_FOR_OBJECTS = 128; + LLVOCache::getInstance()->initCache(LL_PATH_CACHE, CACHE_NUMBER_OF_REGIONS_FOR_OBJECTS, getObjectCacheVersion()); return true; } diff --git a/indra/newview/llfloateravatarpicker.cpp b/indra/newview/llfloateravatarpicker.cpp index 2422596f60..7b91d31d02 100644 --- a/indra/newview/llfloateravatarpicker.cpp +++ b/indra/newview/llfloateravatarpicker.cpp @@ -107,15 +107,11 @@ LLFloaterAvatarPicker::LLFloaterAvatarPicker(const LLSD& key) mCloseOnSelect(FALSE), mExcludeAgentFromSearchResults(FALSE), mContextConeOpacity (0.f), - mContextConeInAlpha(0.f), - mContextConeOutAlpha(0.f), - mContextConeFadeTime(0.f) + mContextConeInAlpha(CONTEXT_CONE_IN_ALPHA), + mContextConeOutAlpha(CONTEXT_CONE_OUT_ALPHA), + mContextConeFadeTime(CONTEXT_CONE_FADE_TIME) { mCommitCallbackRegistrar.add("Refresh.FriendList", boost::bind(&LLFloaterAvatarPicker::populateFriend, this)); - - mContextConeInAlpha = gSavedSettings.getF32("ContextConeInAlpha"); - mContextConeOutAlpha = gSavedSettings.getF32("ContextConeOutAlpha"); - mContextConeFadeTime = gSavedSettings.getF32("ContextConeFadeTime"); } BOOL LLFloaterAvatarPicker::postBuild() diff --git a/indra/newview/llfloatercolorpicker.cpp b/indra/newview/llfloatercolorpicker.cpp index ba91277c79..1672969e82 100644 --- a/indra/newview/llfloatercolorpicker.cpp +++ b/indra/newview/llfloatercolorpicker.cpp @@ -102,9 +102,9 @@ LLFloaterColorPicker::LLFloaterColorPicker (LLColorSwatchCtrl* swatch, BOOL show mActive ( TRUE ), mCanApplyImmediately ( show_apply_immediate ), mContextConeOpacity ( 0.f ), - mContextConeInAlpha ( 0.f ), - mContextConeOutAlpha ( 0.f ), - mContextConeFadeTime ( 0.f ) + mContextConeInAlpha (CONTEXT_CONE_IN_ALPHA), + mContextConeOutAlpha (CONTEXT_CONE_OUT_ALPHA), + mContextConeFadeTime (CONTEXT_CONE_FADE_TIME) { buildFromFile ( "floater_color_picker.xml"); @@ -116,10 +116,6 @@ LLFloaterColorPicker::LLFloaterColorPicker (LLColorSwatchCtrl* swatch, BOOL show mApplyImmediateCheck->setEnabled(FALSE); mApplyImmediateCheck->set(FALSE); } - - mContextConeInAlpha = gSavedSettings.getF32("ContextConeInAlpha"); - mContextConeOutAlpha = gSavedSettings.getF32("ContextConeOutAlpha"); - mContextConeFadeTime = gSavedSettings.getF32("ContextConeFadeTime"); } LLFloaterColorPicker::~LLFloaterColorPicker() diff --git a/indra/newview/llfloaterconversationpreview.cpp b/indra/newview/llfloaterconversationpreview.cpp index 580a3f2610..97327da81a 100644 --- a/indra/newview/llfloaterconversationpreview.cpp +++ b/indra/newview/llfloaterconversationpreview.cpp @@ -37,13 +37,14 @@ const std::string LL_FCP_COMPLETE_NAME("complete_name"); const std::string LL_FCP_ACCOUNT_NAME("user_name"); +const S32 CONVERSATION_HISTORY_PAGE_SIZE = 100; LLFloaterConversationPreview::LLFloaterConversationPreview(const LLSD& session_id) : LLFloater(session_id), mChatHistory(NULL), mSessionID(session_id.asUUID()), mCurrentPage(0), - mPageSize(gSavedSettings.getS32("ConversationHistoryPageSize")), + mPageSize(CONVERSATION_HISTORY_PAGE_SIZE), mAccountName(session_id[LL_FCP_ACCOUNT_NAME]), mCompleteName(session_id[LL_FCP_COMPLETE_NAME]), mMutex(), diff --git a/indra/newview/llfloaterexperiencepicker.cpp b/indra/newview/llfloaterexperiencepicker.cpp index c642da7b83..fe7854b3a5 100644 --- a/indra/newview/llfloaterexperiencepicker.cpp +++ b/indra/newview/llfloaterexperiencepicker.cpp @@ -88,13 +88,10 @@ LLFloaterExperiencePicker::LLFloaterExperiencePicker( const LLSD& key ) :LLFloater(key) ,mSearchPanel(NULL) ,mContextConeOpacity(0.f) - ,mContextConeInAlpha(0.f) - ,mContextConeOutAlpha(0.f) - ,mContextConeFadeTime(0.f) + ,mContextConeInAlpha(CONTEXT_CONE_IN_ALPHA) + ,mContextConeOutAlpha(CONTEXT_CONE_OUT_ALPHA) + ,mContextConeFadeTime(CONTEXT_CONE_FADE_TIME) { - mContextConeInAlpha = gSavedSettings.getF32("ContextConeInAlpha"); - mContextConeOutAlpha = gSavedSettings.getF32("ContextConeOutAlpha"); - mContextConeFadeTime = gSavedSettings.getF32("ContextConeFadeTime"); } LLFloaterExperiencePicker::~LLFloaterExperiencePicker() diff --git a/indra/newview/llscreenchannel.cpp b/indra/newview/llscreenchannel.cpp index 17f2970f99..ea3aa58f94 100644 --- a/indra/newview/llscreenchannel.cpp +++ b/indra/newview/llscreenchannel.cpp @@ -170,8 +170,9 @@ void LLScreenChannelBase::init(S32 channel_left, S32 channel_right) void LLScreenChannelBase::updateRect() { + const S32 CHANNEL_BOTTOM_PANEL_MARGIN = 35; S32 channel_top = getChannelRect().mTop; - S32 channel_bottom = getChannelRect().mBottom + gSavedSettings.getS32("ChannelBottomPanelMargin"); + S32 channel_bottom = getChannelRect().mBottom + CHANNEL_BOTTOM_PANEL_MARGIN; S32 channel_left = getRect().mLeft; S32 channel_right = getRect().mRight; setRect(LLRect(channel_left, channel_top, channel_right, channel_bottom)); diff --git a/indra/newview/llsetkeybinddialog.cpp b/indra/newview/llsetkeybinddialog.cpp index 74844a80e8..dbab7e53b6 100644 --- a/indra/newview/llsetkeybinddialog.cpp +++ b/indra/newview/llsetkeybinddialog.cpp @@ -74,13 +74,10 @@ LLSetKeyBindDialog::LLSetKeyBindDialog(const LLSD& key) pUpdater(NULL), mLastMaskKey(0), mContextConeOpacity(0.f), - mContextConeInAlpha(0.f), - mContextConeOutAlpha(0.f), - mContextConeFadeTime(0.f) + mContextConeInAlpha(CONTEXT_CONE_IN_ALPHA), + mContextConeOutAlpha(CONTEXT_CONE_OUT_ALPHA), + mContextConeFadeTime(CONTEXT_CONE_FADE_TIME) { - mContextConeInAlpha = gSavedSettings.getF32("ContextConeInAlpha"); - mContextConeOutAlpha = gSavedSettings.getF32("ContextConeOutAlpha"); - mContextConeFadeTime = gSavedSettings.getF32("ContextConeFadeTime"); } LLSetKeyBindDialog::~LLSetKeyBindDialog() diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp index 1b0a814c45..dac7a1d3ff 100644 --- a/indra/newview/llstartup.cpp +++ b/indra/newview/llstartup.cpp @@ -2215,7 +2215,7 @@ bool idle_startup() static LLFrameTimer wearables_timer; const F32 wearables_time = wearables_timer.getElapsedTimeF32(); - static LLCachedControl max_wearables_time(gSavedSettings, "ClothingLoadingDelay"); + const F32 MAX_WEARABLES_TIME = 10.f; if (!gAgent.isOutfitChosen() && isAgentAvatarValid()) { @@ -2234,7 +2234,7 @@ bool idle_startup() display_startup(); - if (gAgent.isOutfitChosen() && (wearables_time > max_wearables_time)) + if (gAgent.isOutfitChosen() && (wearables_time > MAX_WEARABLES_TIME)) { if (gInventory.isInventoryUsable()) { diff --git a/indra/newview/lltoolpie.cpp b/indra/newview/lltoolpie.cpp index 1ea5983466..17a7ad9d01 100644 --- a/indra/newview/lltoolpie.cpp +++ b/indra/newview/lltoolpie.cpp @@ -86,8 +86,8 @@ LLToolPie::LLToolPie() mMouseSteerX(-1), mMouseSteerY(-1), mClickAction(0), - mClickActionBuyEnabled( gSavedSettings.getBOOL("ClickActionBuyEnabled") ), - mClickActionPayEnabled( gSavedSettings.getBOOL("ClickActionPayEnabled") ), + mClickActionBuyEnabled( TRUE ), + mClickActionPayEnabled( TRUE ), mDoubleClickTimer() { } diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp index 668214a47c..1fe076c0a8 100644 --- a/indra/newview/llviewercontrol.cpp +++ b/indra/newview/llviewercontrol.cpp @@ -370,15 +370,6 @@ static bool handleChatFontSizeChanged(const LLSD& newvalue) return true; } -static bool handleChatPersistTimeChanged(const LLSD& newvalue) -{ - if(gConsole) - { - gConsole->setLinePersistTime((F32) newvalue.asReal()); - } - return true; -} - static bool handleConsoleMaxLinesChanged(const LLSD& newvalue) { if(gConsole) @@ -804,7 +795,6 @@ void settings_setup_listeners() setting_setup_signal_listener(gSavedSettings, "RenderPerformanceTest", handleRenderPerfTestChanged); setting_setup_signal_listener(gSavedSettings, "TextureMemory", handleVideoMemoryChanged); setting_setup_signal_listener(gSavedSettings, "ChatFontSize", handleChatFontSizeChanged); - setting_setup_signal_listener(gSavedSettings, "ChatPersistTime", handleChatPersistTimeChanged); setting_setup_signal_listener(gSavedSettings, "ConsoleMaxLines", handleConsoleMaxLinesChanged); setting_setup_signal_listener(gSavedSettings, "UploadBakedTexOld", handleUploadBakedTexOldChanged); setting_setup_signal_listener(gSavedSettings, "UseOcclusion", handleUseOcclusionChanged); @@ -933,8 +923,6 @@ DECL_LLCC(LLColor4U, LLColor4U(255, 200, 100, 255)); LLSD test_llsd = LLSD()["testing1"] = LLSD()["testing2"]; DECL_LLCC(LLSD, test_llsd); -static LLCachedControl test_BrowserHomePage("BrowserHomePage", "hahahahahha", "Not the real comment"); - void test_cached_control() { #define do { TEST_LLCC(T, V) if((T)mySetting_##T != V) LL_ERRS() << "Fail "#T << LL_ENDL; } while(0) @@ -951,8 +939,6 @@ void test_cached_control() TEST_LLCC(LLColor3, LLColor3(1.0f, 0.f, 0.5f)); TEST_LLCC(LLColor4U, LLColor4U(255, 200, 100, 255)); //There's no LLSD comparsion for LLCC yet. TEST_LLCC(LLSD, test_llsd); - - if((std::string)test_BrowserHomePage != "http://www.secondlife.com") LL_ERRS() << "Fail BrowserHomePage" << LL_ENDL; } #endif // TEST_CACHED_CONTROL diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp index e8fd74b37b..9384f36fd2 100644 --- a/indra/newview/llviewerwindow.cpp +++ b/indra/newview/llviewerwindow.cpp @@ -2148,13 +2148,15 @@ void LLViewerWindow::initBase() gFloaterView->setFloaterSnapView(main_view->getChild("floater_snap_region")->getHandle()); gSnapshotFloaterView = main_view->getChild("Snapshot Floater View"); + const F32 CHAT_PERSIST_TIME = 20.f; + // Console llassert( !gConsole ); LLConsole::Params cp; cp.name("console"); cp.max_lines(gSavedSettings.getS32("ConsoleBufferSize")); cp.rect(getChatConsoleRect()); - cp.persist_time(gSavedSettings.getF32("ChatPersistTime")); + cp.persist_time(CHAT_PERSIST_TIME); cp.font_size_index(gSavedSettings.getS32("ChatFontSize")); cp.follows.flags(FOLLOWS_LEFT | FOLLOWS_RIGHT | FOLLOWS_BOTTOM); gConsole = LLUICtrlFactory::create(cp); diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index b5dc1dee94..ff5af7e271 100644 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -9262,9 +9262,7 @@ void LLVOAvatar::parseAppearanceMessage(LLMessageSystem* mesgsys, LLAppearanceMe // Parse visual params, if any. S32 num_blocks = mesgsys->getNumberOfBlocksFast(_PREHASH_VisualParam); - static LLCachedControl block_some_avatars(gSavedSettings, "BlockSomeAvatarAppearanceVisualParams"); - bool drop_visual_params_debug = block_some_avatars && (ll_rand(2) == 0); // pretend that ~12% of AvatarAppearance messages arrived without a VisualParam block, for testing - if( num_blocks > 1 && !drop_visual_params_debug) + if( num_blocks > 1) { //LL_DEBUGS("Avatar") << avString() << " handle visual params, num_blocks " << num_blocks << LL_ENDL; @@ -9309,14 +9307,7 @@ void LLVOAvatar::parseAppearanceMessage(LLMessageSystem* mesgsys, LLAppearanceMe } else { - if (drop_visual_params_debug) - { - LL_INFOS() << "Debug-faked lack of parameters on AvatarAppearance for object: " << getID() << LL_ENDL; - } - else - { - LL_DEBUGS("Avatar") << "AvatarAppearance msg received without any parameters, object: " << getID() << LL_ENDL; - } + LL_DEBUGS("Avatar") << "AvatarAppearance msg received without any parameters, object: " << getID() << LL_ENDL; } LLVisualParam* appearance_version_param = getVisualParam(11000); -- cgit v1.2.3 From 145a5ffe7f57ec87b0604c2e06104a4eb3cb8644 Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Fri, 22 Sep 2023 01:01:42 +0300 Subject: SL-15039 Prune unused preferences #3 DebugInventoryFilters DebugShowXUINames DebugSlshareLogTag DebugStat**** DefaultBlankNormalTexture DefaultObjectNormalTexture DefaultObjectSpecularTexture DefaultUploadCost DisplayAvatarAgentTarget DisplayChat DisplayDebug DisplayDebugConsole DisplayIM DisplayLinden DisplayRegion DragAndDropToolTipDelay DragAndDropDistanceThreshold DropShadowButton DropShadowFloater DropShadowSlider DropShadowTooltip UIImgWhiteUUID UseEnvironmentFromRegion UseDayCycle WaterPresetName SkyPresetName DayCycleName DestinationGuideHintTimeout SidePanelHintTimeout DisablePrecacheDelayAfterTeleporting --- indra/llprimitive/llprimitive.cpp | 6 +- indra/llprimitive/llprimitive.h | 2 +- indra/llui/llbutton.cpp | 1 + indra/llui/llbutton.h | 2 +- indra/llui/llcombobox.cpp | 15 +- indra/llui/llfloater.cpp | 3 +- indra/llui/llfolderviewitem.cpp | 4 +- indra/llui/llmenugl.cpp | 3 +- indra/llui/llmodaldialog.cpp | 3 +- indra/llui/lltoolbar.cpp | 3 +- indra/llui/llui.h | 2 +- indra/llui/lluictrl.h | 1 + indra/newview/app_settings/settings.xml | 766 +-------------------- indra/newview/llagentcamera.cpp | 3 +- indra/newview/llfloaterenvironmentadjust.cpp | 2 +- indra/newview/lllocationinputctrl.cpp | 3 +- indra/newview/llnavigationbar.cpp | 3 +- indra/newview/llpaneleditwater.cpp | 2 +- indra/newview/llpanelface.cpp | 12 +- indra/newview/llpanelobject.cpp | 6 +- indra/newview/lltexturectrl.cpp | 11 +- indra/newview/lltexturectrl.h | 7 + indra/newview/lltoastalertpanel.cpp | 3 +- indra/newview/lltooldraganddrop.cpp | 7 +- indra/newview/lltoolpie.cpp | 3 +- indra/newview/llviewerwindow.cpp | 6 +- .../skins/default/xui/en/floater_media_browser.xml | 12 +- 27 files changed, 69 insertions(+), 822 deletions(-) diff --git a/indra/llprimitive/llprimitive.cpp b/indra/llprimitive/llprimitive.cpp index 67c225d25d..bfc9bc0861 100644 --- a/indra/llprimitive/llprimitive.cpp +++ b/indra/llprimitive/llprimitive.cpp @@ -107,7 +107,7 @@ const F32 FLEXIBLE_OBJECT_DEFAULT_LENGTH = 1.0f; const BOOL FLEXIBLE_OBJECT_DEFAULT_USING_COLLISION_SPHERE = FALSE; const BOOL FLEXIBLE_OBJECT_DEFAULT_RENDERING_COLLISION_SPHERE = FALSE; -const char *SCULPT_DEFAULT_TEXTURE = "be293869-d0d9-0a69-5989-ad27f1946fd4"; // old inverted texture: "7595d345-a24c-e7ef-f0bd-78793792133e"; +const LLUUID SCULPT_DEFAULT_TEXTURE("be293869-d0d9-0a69-5989-ad27f1946fd4"); // old inverted texture: "7595d345-a24c-e7ef-f0bd-78793792133e"; // Texture rotations are sent over the wire as a S16. This is used to scale the actual float // value to a S16. Don't use 7FFF as it introduces some odd rounding with 180 since it @@ -1946,7 +1946,7 @@ bool LLFlexibleObjectData::fromLLSD(LLSD& sd) LLSculptParams::LLSculptParams() { mType = PARAMS_SCULPT; - mSculptTexture.set(SCULPT_DEFAULT_TEXTURE); + mSculptTexture = SCULPT_DEFAULT_TEXTURE; mSculptType = LL_SCULPT_TYPE_SPHERE; } @@ -2032,7 +2032,7 @@ void LLSculptParams::setSculptTexture(const LLUUID& texture_id, U8 sculpt_type) U8 flags = sculpt_type & LL_SCULPT_FLAG_MASK; if (sculpt_type != (type | flags) || type > LL_SCULPT_TYPE_MAX) { - mSculptTexture.set(SCULPT_DEFAULT_TEXTURE); + mSculptTexture = SCULPT_DEFAULT_TEXTURE; mSculptType = LL_SCULPT_TYPE_SPHERE; } else diff --git a/indra/llprimitive/llprimitive.h b/indra/llprimitive/llprimitive.h index 309b18faa9..ba76fe1ac5 100644 --- a/indra/llprimitive/llprimitive.h +++ b/indra/llprimitive/llprimitive.h @@ -89,7 +89,7 @@ extern const F32 OBJECT_REV_MIN; extern const F32 OBJECT_REV_MAX; extern const F32 OBJECT_REV_INC; -extern const char *SCULPT_DEFAULT_TEXTURE; +extern const LLUUID SCULPT_DEFAULT_TEXTURE; //============================================================================ diff --git a/indra/llui/llbutton.cpp b/indra/llui/llbutton.cpp index fe9908a475..061c24db50 100644 --- a/indra/llui/llbutton.cpp +++ b/indra/llui/llbutton.cpp @@ -62,6 +62,7 @@ template class LLButton* LLView::getChild( S32 LLBUTTON_H_PAD = 4; S32 BTN_HEIGHT_SMALL= 23; S32 BTN_HEIGHT = 23; +S32 BTN_DROP_SHADOW = 2; LLButton::Params::Params() : label_selected("label_selected"), // requires is_toggle true diff --git a/indra/llui/llbutton.h b/indra/llui/llbutton.h index ccd31e90c0..ab64440c19 100644 --- a/indra/llui/llbutton.h +++ b/indra/llui/llbutton.h @@ -43,10 +43,10 @@ // // PLEASE please use these "constants" when building your own buttons. -// They are loaded from settings.xml at run time. extern S32 LLBUTTON_H_PAD; extern S32 BTN_HEIGHT_SMALL; extern S32 BTN_HEIGHT; +extern S32 BTN_DROP_SHADOW; // // Helpful functions diff --git a/indra/llui/llcombobox.cpp b/indra/llui/llcombobox.cpp index 9ca05a16f3..7a925c0659 100644 --- a/indra/llui/llcombobox.cpp +++ b/indra/llui/llcombobox.cpp @@ -482,8 +482,6 @@ void LLComboBox::onFocusLost() void LLComboBox::setButtonVisible(BOOL visible) { - static LLUICachedControl drop_shadow_button ("DropShadowButton", 0); - mButton->setVisible(visible); if (mTextEntry) { @@ -491,7 +489,7 @@ void LLComboBox::setButtonVisible(BOOL visible) if (visible) { S32 arrow_width = mArrowImage ? mArrowImage->getWidth() : 0; - text_entry_rect.mRight -= llmax(8,arrow_width) + 2 * drop_shadow_button; + text_entry_rect.mRight -= llmax(8,arrow_width) + 2 * BTN_DROP_SHADOW; } //mTextEntry->setRect(text_entry_rect); mTextEntry->reshape(text_entry_rect.getWidth(), text_entry_rect.getHeight(), TRUE); @@ -530,19 +528,18 @@ void LLComboBox::setEnabledByValue(const LLSD& value, BOOL enabled) void LLComboBox::createLineEditor(const LLComboBox::Params& p) { - static LLUICachedControl drop_shadow_button ("DropShadowButton", 0); LLRect rect = getLocalRect(); if (mAllowTextEntry) { S32 arrow_width = mArrowImage ? mArrowImage->getWidth() : 0; - S32 shadow_size = drop_shadow_button; + S32 shadow_size = BTN_DROP_SHADOW; mButton->setRect(LLRect( getRect().getWidth() - llmax(8,arrow_width) - 2 * shadow_size, rect.mTop, rect.mRight, rect.mBottom)); mButton->setTabStop(FALSE); mButton->setHAlign(LLFontGL::HCENTER); LLRect text_entry_rect(0, getRect().getHeight(), getRect().getWidth(), 0); - text_entry_rect.mRight -= llmax(8,arrow_width) + 2 * drop_shadow_button; + text_entry_rect.mRight -= llmax(8,arrow_width) + 2 * BTN_DROP_SHADOW; // clear label on button std::string cur_label = mButton->getLabelSelected(); LLLineEditor::Params params = p.combo_editor; @@ -1081,13 +1078,11 @@ void LLComboBox::onSetHighlight() const void LLComboBox::imageLoaded() { - static LLUICachedControl drop_shadow_button("DropShadowButton", 0); - if (mAllowTextEntry) { LLRect rect = getLocalRect(); S32 arrow_width = mArrowImage ? mArrowImage->getWidth() : 0; - S32 shadow_size = drop_shadow_button; + S32 shadow_size = BTN_DROP_SHADOW; mButton->setRect(LLRect(getRect().getWidth() - llmax(8, arrow_width) - 2 * shadow_size, rect.mTop, rect.mRight, rect.mBottom)); if (mButton->getVisible()) @@ -1096,7 +1091,7 @@ void LLComboBox::imageLoaded() if (mTextEntry) { LLRect text_entry_rect(0, getRect().getHeight(), getRect().getWidth(), 0); - text_entry_rect.mRight -= llmax(8, arrow_width) + 2 * drop_shadow_button; + text_entry_rect.mRight -= llmax(8, arrow_width) + 2 * BTN_DROP_SHADOW; mTextEntry->reshape(text_entry_rect.getWidth(), text_entry_rect.getHeight(), TRUE); } } diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp index 2303cd24b7..d08084cdf5 100644 --- a/indra/llui/llfloater.cpp +++ b/indra/llui/llfloater.cpp @@ -1961,10 +1961,9 @@ void LLFloater::drawShadow(LLPanel* panel) S32 right = panel->getRect().getWidth() - LLPANEL_BORDER_WIDTH; S32 bottom = LLPANEL_BORDER_WIDTH; - static LLUICachedControl shadow_offset_S32 ("DropShadowFloater", 0); static LLUIColor shadow_color_cached = LLUIColorTable::instance().getColor("ColorDropShadow"); LLColor4 shadow_color = shadow_color_cached; - F32 shadow_offset = (F32)shadow_offset_S32; + F32 shadow_offset = (F32)DROP_SHADOW_FLOATER; if (!panel->isBackgroundOpaque()) { diff --git a/indra/llui/llfolderviewitem.cpp b/indra/llui/llfolderviewitem.cpp index 5319af1b60..ed0e705fd5 100644 --- a/indra/llui/llfolderviewitem.cpp +++ b/indra/llui/llfolderviewitem.cpp @@ -596,15 +596,13 @@ BOOL LLFolderViewItem::handleMouseDown( S32 x, S32 y, MASK mask ) BOOL LLFolderViewItem::handleHover( S32 x, S32 y, MASK mask ) { - static LLCachedControl drag_and_drop_threshold(*LLUI::getInstance()->mSettingGroups["config"],"DragAndDropDistanceThreshold", 3); - mIsMouseOverTitle = (y > (getRect().getHeight() - mItemHeight)); if( hasMouseCapture() && isMovable() ) { LLFolderView* root = getRoot(); - if( (x - mDragStartX) * (x - mDragStartX) + (y - mDragStartY) * (y - mDragStartY) > drag_and_drop_threshold() * drag_and_drop_threshold() + if( (x - mDragStartX) * (x - mDragStartX) + (y - mDragStartY) * (y - mDragStartY) > DRAG_N_DROP_DISTANCE_THRESHOLD * DRAG_N_DROP_DISTANCE_THRESHOLD && root->getAllowDrag() && root->getCurSelectedItem() && root->startDrag()) diff --git a/indra/llui/llmenugl.cpp b/indra/llui/llmenugl.cpp index 32c5ceb20e..fe25ac1647 100644 --- a/indra/llui/llmenugl.cpp +++ b/indra/llui/llmenugl.cpp @@ -3220,10 +3220,9 @@ void LLMenuGL::draw( void ) } if (mDropShadowed && !mTornOff) { - static LLUICachedControl drop_shadow_floater ("DropShadowFloater", 0); static LLUIColor color_drop_shadow = LLUIColorTable::instance().getColor("ColorDropShadow"); gl_drop_shadow(0, getRect().getHeight(), getRect().getWidth(), 0, - color_drop_shadow, drop_shadow_floater ); + color_drop_shadow, DROP_SHADOW_FLOATER); } if( mBgVisible ) diff --git a/indra/llui/llmodaldialog.cpp b/indra/llui/llmodaldialog.cpp index 3e5978eb59..22d98469ec 100644 --- a/indra/llui/llmodaldialog.cpp +++ b/indra/llui/llmodaldialog.cpp @@ -284,10 +284,9 @@ BOOL LLModalDialog::handleKeyHere(KEY key, MASK mask ) void LLModalDialog::draw() { static LLUIColor shadow_color = LLUIColorTable::instance().getColor("ColorDropShadow"); - static LLUICachedControl shadow_lines ("DropShadowFloater", 0); gl_drop_shadow( 0, getRect().getHeight(), getRect().getWidth(), 0, - shadow_color, shadow_lines); + shadow_color, DROP_SHADOW_FLOATER); LLFloater::draw(); diff --git a/indra/llui/lltoolbar.cpp b/indra/llui/lltoolbar.cpp index 2707f7a15c..58ecf3e603 100644 --- a/indra/llui/lltoolbar.cpp +++ b/indra/llui/lltoolbar.cpp @@ -1134,8 +1134,7 @@ BOOL LLToolBarButton::handleHover(S32 x, S32 y, MASK mask) BOOL handled = FALSE; S32 mouse_distance_squared = (x - mMouseDownX) * (x - mMouseDownX) + (y - mMouseDownY) * (y - mMouseDownY); - static LLCachedControl drag_threshold(*LLUI::getInstance()->mSettingGroups["config"], "DragAndDropDistanceThreshold", 3); - if (mouse_distance_squared > drag_threshold * drag_threshold + if (mouse_distance_squared > DRAG_N_DROP_DISTANCE_THRESHOLD * DRAG_N_DROP_DISTANCE_THRESHOLD && hasMouseCapture() && mStartDragItemCallback && mHandleDragItemCallback) { diff --git a/indra/llui/llui.h b/indra/llui/llui.h index 30dbd7248f..868e1d21a6 100644 --- a/indra/llui/llui.h +++ b/indra/llui/llui.h @@ -53,7 +53,7 @@ class LLWindow; class LLView; class LLHelp; - +const S32 DRAG_N_DROP_DISTANCE_THRESHOLD = 3; // this enum is used by the llview.h (viewer) and the llassetstorage.h (viewer and sim) enum EDragAndDropType { diff --git a/indra/llui/lluictrl.h b/indra/llui/lluictrl.h index 67dd24341c..424b4879ce 100644 --- a/indra/llui/lluictrl.h +++ b/indra/llui/lluictrl.h @@ -41,6 +41,7 @@ const BOOL TAKE_FOCUS_YES = TRUE; const BOOL TAKE_FOCUS_NO = FALSE; +const S32 DROP_SHADOW_FLOATER = 5; class LLUICtrl : public LLView, public boost::signals2::trackable diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index 7a8c1abd7a..654ab76b30 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -2029,17 +2029,6 @@ Value 1 - DebugInventoryFilters - - Comment - Turn on debugging display for inventory filtering - Persist - 1 - Type - Boolean - Value - 0 - DebugPermissions Comment @@ -2152,454 +2141,25 @@ DebugShowUploadCost - Comment - Show mesh upload cost - Persist - 1 - Type - Boolean - Value - 1 - - DebugShowXUINames - - Comment - Show tooltips with XUI path to widget - Persist - 0 - Type - Boolean - Value - 0 - - DebugSlshareLogTag - - Comment - Request slshare-service debug logging - Persist - 0 - Type - String - Value - - - DebugStatModeFPS - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeBandwidth - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModePacketLoss - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatMode - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeKTrisDrawnFr - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeKTrisDrawnSec - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeTotalObjs - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeNewObjs - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeTextureCount - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeRawCount - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeGLMem - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeFormattedMem - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeRawMem - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeBoundMem - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModePacketsIn - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModePacketsOut - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeObjects - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeTexture - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeAsset - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeLayers - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeActualIn - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeActualOut - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeTimeDialation - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeSimFPS - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModePhysicsFPS - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModePinnedObjects - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeLowLODObjects - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeMemoryAllocated - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeAgentUpdatesSec - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeMainAgents - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeChildAgents - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeSimObjects - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeSimActiveObjects - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeSimActiveScripts - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeSimScriptEvents - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeSimInPPS - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeSimOutPPS - - Comment - Mode of stat in Statistics floater - Persist - 1 - Type - S32 - Value - -1 - - DebugStatModeSimPendingDownloads + Comment + Show mesh upload cost + Persist + 1 + Type + Boolean + Value + 1 + + DebugShowXUINames Comment - Mode of stat in Statistics floater + Show tooltips with XUI path to widget Persist - 1 + 0 Type - S32 + Boolean Value - -1 + 0 SimPendingUploads @@ -2788,17 +2348,6 @@ Value 0 - DefaultBlankNormalTexture - - Comment - Texture used as 'Blank' in texture picker for normal maps. (UUID texture reference) - Persist - 1 - Type - String - Value - 5b53359e-59dd-d8a2-04c3-9e65134da47a - DefaultFemaleAvatar Comment @@ -2832,28 +2381,6 @@ Value Male Shape & Outfit - DefaultObjectNormalTexture - - Comment - Texture used as 'Default' in texture picker for normal map. (UUID texture reference) - Persist - 1 - Type - String - Value - 85f28839-7a1c-b4e3-d71d-967792970a7b - - DefaultObjectSpecularTexture - - Comment - Texture used as 'Default' in texture picker for specular map. (UUID texture reference) - Persist - 1 - Type - String - Value - 87e0e8f7-8729-1ea8-cfc9-8915773009db - DefaultObjectTexture Comment @@ -2865,17 +2392,6 @@ Value 89556747-24cb-43ed-920b-47caed15465f - DefaultUploadCost - - Comment - Default sound/image/file upload cost(in case economy data is not available). - Persist - 1 - Type - U32 - Value - 10 - DestinationGuideURL Comment @@ -2986,83 +2502,6 @@ Value 1 - DisplayAvatarAgentTarget - - Comment - Show avatar positioning locators (animation debug) - Persist - 1 - Type - Boolean - Value - 0 - - DisplayChat - - Comment - Display Latest Chat message on LCD - Persist - 1 - Type - Boolean - Value - 1 - - DisplayDebug - - Comment - Display Network Information on LCD - Persist - 1 - Type - Boolean - Value - 1 - - DisplayDebugConsole - - Comment - Display Console Debug Information on LCD - Persist - 1 - Type - Boolean - Value - 1 - - DisplayIM - - Comment - Display Latest IM message on LCD - Persist - 1 - Type - Boolean - Value - 1 - - DisplayLinden - - Comment - Display Account Information on LCD - Persist - 1 - Type - Boolean - Value - 1 - - DisplayRegion - - Comment - Display Location information on LCD - Persist - 1 - Type - Boolean - Value - 1 - DisplayTimecode Comment @@ -3129,72 +2568,6 @@ Value 1 - DragAndDropToolTipDelay - - Comment - Seconds before displaying tooltip when performing drag and drop operation - Persist - 1 - Type - F32 - Value - 0.10000000149 - - DragAndDropDistanceThreshold - - Comment - Number of pixels that mouse should move before triggering drag and drop mode - Persist - 1 - Type - S32 - Value - 3 - - DropShadowButton - - Comment - Drop shadow width for buttons (pixels) - Persist - 1 - Type - S32 - Value - 2 - - DropShadowFloater - - Comment - Drop shadow width for floaters (pixels) - Persist - 1 - Type - S32 - Value - 5 - - DropShadowSlider - - Comment - Drop shadow width for sliders (pixels) - Persist - 1 - Type - S32 - Value - 3 - - DropShadowTooltip - - Comment - Drop shadow width for tooltips (pixels) - Persist - 1 - Type - S32 - Value - 4 - DynamicCameraStrength Comment @@ -12822,17 +12195,6 @@ Value 5748decc-f629-461c-9a36-a35a221fe21f - UIImgWhiteUUID - - Comment - - Persist - 0 - Type - String - Value - 5748decc-f629-461c-9a36-a35a221fe21f - UILineEditorCursorThickness Comment @@ -13636,17 +12998,6 @@ Value 1 - UseEnvironmentFromRegion - - Comment - Choose whether to use the region's environment settings, or override them with the local settings. - Persist - 1 - Type - Boolean - Value - 1 - EnvironmentPersistAcrossLogin Comment @@ -13658,62 +13009,6 @@ Value 0 - UseDayCycle - - Comment - Whether to use use a day cycle or a fixed sky. - Persist - 1 - Type - Boolean - Value - 1 - - WaterPresetName - - Comment - Water preset to use. May be superseded by region settings. - Persist - 1 - Type - String - Value - Default - - SkyPresetName - - Comment - Sky preset to use. May be superseded by region settings or by a day cycle (see DayCycleName). - Persist - 1 - Type - String - Value - Default - - DayCycleName - - Comment - Day cycle to use. May be superseded by region settings. - Persist - 1 - Type - String - Value - Default - - UseExternalBrowser - - - Comment - (Deprecated) Use default browser when opening web pages instead of in-world browser. - Persist - 1 - Type - Boolean - Value - 1 - PreferredBrowserBehavior Comment @@ -14976,28 +14271,6 @@ Value 120.0 - DestinationGuideHintTimeout - - Comment - Number of seconds to wait before telling resident about destination guide. - Persist - 1 - Type - F32 - Value - 1200.0 - - SidePanelHintTimeout - - Comment - Number of seconds to wait before telling resident about side panel. - Persist - 1 - Type - F32 - Value - 300.0 - GroupMembersSortOrder Comment @@ -16065,17 +15338,6 @@ Value 7000 - DisablePrecacheDelayAfterTeleporting - - Comment - Disables the artificial delay in the viewer that precaches some incoming assets - Persist - 0 - Type - Boolean - Value - 0 - VersionChannelName Comment diff --git a/indra/newview/llagentcamera.cpp b/indra/newview/llagentcamera.cpp index d2fe570069..adea8a2bb4 100644 --- a/indra/newview/llagentcamera.cpp +++ b/indra/newview/llagentcamera.cpp @@ -1919,7 +1919,8 @@ LLVector3d LLAgentCamera::calcCameraPositionTargetGlobal(BOOL *hit_limit) } else { - target_lag = vel * gSavedSettings.getF32("DynamicCameraStrength") / 30.f; + LLCachedControl dynamic_camera_strength(gSavedSettings, "DynamicCameraStrength"); + target_lag = vel * dynamic_camera_strength / 30.f; } mCameraLag = lerp(mCameraLag, target_lag, lag_interp); diff --git a/indra/newview/llfloaterenvironmentadjust.cpp b/indra/newview/llfloaterenvironmentadjust.cpp index 95d6a2d652..0b270103cc 100644 --- a/indra/newview/llfloaterenvironmentadjust.cpp +++ b/indra/newview/llfloaterenvironmentadjust.cpp @@ -114,7 +114,7 @@ BOOL LLFloaterEnvironmentAdjust::postBuild() getChild(FIELD_SKY_CLOUD_MAP)->setAllowNoTexture(TRUE); getChild(FIELD_WATER_NORMAL_MAP)->setDefaultImageAssetID(LLSettingsWater::GetDefaultWaterNormalAssetId()); - getChild(FIELD_WATER_NORMAL_MAP)->setBlankImageAssetID(LLUUID(gSavedSettings.getString("DefaultBlankNormalTexture"))); + getChild(FIELD_WATER_NORMAL_MAP)->setBlankImageAssetID(DEFAULT_BLANK_NORMAL_TEXTURE); getChild(FIELD_WATER_NORMAL_MAP)->setCommitCallback([this](LLUICtrl *, const LLSD &) { onWaterMapChanged(); }); refresh(); diff --git a/indra/newview/lllocationinputctrl.cpp b/indra/newview/lllocationinputctrl.cpp index d6f3068610..d84b6990b9 100644 --- a/indra/newview/lllocationinputctrl.cpp +++ b/indra/newview/lllocationinputctrl.cpp @@ -230,10 +230,9 @@ LLLocationInputCtrl::LLLocationInputCtrl(const LLLocationInputCtrl::Params& p) // Can't access old mTextEntry fields as they are protected, so lets build new params // That is C&P from LLComboBox::createLineEditor function - static LLUICachedControl drop_shadow_button ("DropShadowButton", 0); S32 arrow_width = mArrowImage ? mArrowImage->getWidth() : 0; LLRect text_entry_rect(0, getRect().getHeight(), getRect().getWidth(), 0); - text_entry_rect.mRight -= llmax(8,arrow_width) + 2 * drop_shadow_button; + text_entry_rect.mRight -= llmax(8,arrow_width) + 2 * BTN_DROP_SHADOW; LLLineEditor::Params params = p.combo_editor; params.rect(text_entry_rect); diff --git a/indra/newview/llnavigationbar.cpp b/indra/newview/llnavigationbar.cpp index f5ee1171d9..61448828d1 100644 --- a/indra/newview/llnavigationbar.cpp +++ b/indra/newview/llnavigationbar.cpp @@ -352,10 +352,9 @@ void LLNavigationBar::draw() { if (isBackgroundVisible()) { - static LLUICachedControl drop_shadow_floater ("DropShadowFloater", 0); static LLUIColor color_drop_shadow = LLUIColorTable::instance().getColor("ColorDropShadow"); gl_drop_shadow(0, getRect().getHeight(), getRect().getWidth(), 0, - color_drop_shadow, drop_shadow_floater ); + color_drop_shadow, DROP_SHADOW_FLOATER); } LLPanel::draw(); diff --git a/indra/newview/llpaneleditwater.cpp b/indra/newview/llpaneleditwater.cpp index a09964e17d..fc9ca4e47e 100644 --- a/indra/newview/llpaneleditwater.cpp +++ b/indra/newview/llpaneleditwater.cpp @@ -89,7 +89,7 @@ BOOL LLPanelSettingsWaterMainTab::postBuild() getChild(FIELD_WATER_UNDERWATER_MOD)->setCommitCallback([this](LLUICtrl *, const LLSD &) { onFogUnderWaterChanged(); }); mTxtNormalMap->setDefaultImageAssetID(LLSettingsWater::GetDefaultWaterNormalAssetId()); - mTxtNormalMap->setBlankImageAssetID(LLUUID( gSavedSettings.getString( "DefaultBlankNormalTexture" ))); + mTxtNormalMap->setBlankImageAssetID(DEFAULT_BLANK_NORMAL_TEXTURE); mTxtNormalMap->setCommitCallback([this](LLUICtrl *, const LLSD &) { onNormalMapChanged(); }); getChild(FIELD_WATER_WAVE2_XY)->setCommitCallback([this](LLUICtrl *, const LLSD &) { onSmallWaveChanged(); }); diff --git a/indra/newview/llpanelface.cpp b/indra/newview/llpanelface.cpp index cbb87f63bb..eb392b3032 100644 --- a/indra/newview/llpanelface.cpp +++ b/indra/newview/llpanelface.cpp @@ -190,7 +190,7 @@ BOOL LLPanelFace::postBuild() mTextureCtrl = getChild("texture control"); if(mTextureCtrl) { - mTextureCtrl->setDefaultImageAssetID(LLUUID( gSavedSettings.getString( "DefaultObjectTexture" ))); + mTextureCtrl->setDefaultImageAssetID(DEFAULT_OBJECT_TEXTURE); mTextureCtrl->setCommitCallback( boost::bind(&LLPanelFace::onCommitTexture, this, _2) ); mTextureCtrl->setOnCancelCallback( boost::bind(&LLPanelFace::onCancelTexture, this, _2) ); mTextureCtrl->setOnSelectCallback( boost::bind(&LLPanelFace::onSelectTexture, this, _2) ); @@ -207,7 +207,7 @@ BOOL LLPanelFace::postBuild() mShinyTextureCtrl = getChild("shinytexture control"); if(mShinyTextureCtrl) { - mShinyTextureCtrl->setDefaultImageAssetID(LLUUID( gSavedSettings.getString( "DefaultObjectSpecularTexture" ))); + mShinyTextureCtrl->setDefaultImageAssetID(DEFAULT_OBJECT_SPECULAR_TEXTURE); mShinyTextureCtrl->setCommitCallback( boost::bind(&LLPanelFace::onCommitSpecularTexture, this, _2) ); mShinyTextureCtrl->setOnCancelCallback( boost::bind(&LLPanelFace::onCancelSpecularTexture, this, _2) ); mShinyTextureCtrl->setOnSelectCallback( boost::bind(&LLPanelFace::onSelectSpecularTexture, this, _2) ); @@ -224,8 +224,8 @@ BOOL LLPanelFace::postBuild() mBumpyTextureCtrl = getChild("bumpytexture control"); if(mBumpyTextureCtrl) { - mBumpyTextureCtrl->setDefaultImageAssetID(LLUUID( gSavedSettings.getString( "DefaultObjectNormalTexture" ))); - mBumpyTextureCtrl->setBlankImageAssetID(LLUUID( gSavedSettings.getString( "DefaultBlankNormalTexture" ))); + mBumpyTextureCtrl->setDefaultImageAssetID(DEFAULT_OBJECT_NORMAL_TEXTURE); + mBumpyTextureCtrl->setBlankImageAssetID(DEFAULT_BLANK_NORMAL_TEXTURE); mBumpyTextureCtrl->setCommitCallback( boost::bind(&LLPanelFace::onCommitNormalTexture, this, _2) ); mBumpyTextureCtrl->setOnCancelCallback( boost::bind(&LLPanelFace::onCancelNormalTexture, this, _2) ); mBumpyTextureCtrl->setOnSelectCallback( boost::bind(&LLPanelFace::onSelectNormalTexture, this, _2) ); @@ -3797,7 +3797,7 @@ void LLPanelFace::onCopyTexture() LLUUID id = mat_data["NormMap"].asUUID(); if (id.notNull() && !get_can_copy_texture(id)) { - mat_data["NormMap"] = LLUUID(gSavedSettings.getString("DefaultObjectTexture")); + mat_data["NormMap"] = DEFAULT_OBJECT_TEXTURE; mat_data["NormMapNoCopy"] = true; } @@ -3807,7 +3807,7 @@ void LLPanelFace::onCopyTexture() LLUUID id = mat_data["SpecMap"].asUUID(); if (id.notNull() && !get_can_copy_texture(id)) { - mat_data["SpecMap"] = LLUUID(gSavedSettings.getString("DefaultObjectTexture")); + mat_data["SpecMap"] = DEFAULT_OBJECT_TEXTURE; mat_data["SpecMapNoCopy"] = true; } diff --git a/indra/newview/llpanelobject.cpp b/indra/newview/llpanelobject.cpp index 2da431955f..c8256640f2 100644 --- a/indra/newview/llpanelobject.cpp +++ b/indra/newview/llpanelobject.cpp @@ -244,7 +244,7 @@ BOOL LLPanelObject::postBuild() mCtrlSculptTexture = getChild("sculpt texture control"); if (mCtrlSculptTexture) { - mCtrlSculptTexture->setDefaultImageAssetID(LLUUID(SCULPT_DEFAULT_TEXTURE)); + mCtrlSculptTexture->setDefaultImageAssetID(SCULPT_DEFAULT_TEXTURE); mCtrlSculptTexture->setCommitCallback( boost::bind(&LLPanelObject::onCommitSculpt, this, _2 )); mCtrlSculptTexture->setOnCancelCallback( boost::bind(&LLPanelObject::onCancelSculpt, this, _2 )); mCtrlSculptTexture->setOnSelectCallback( boost::bind(&LLPanelObject::onSelectSculpt, this, _2 )); @@ -2026,7 +2026,7 @@ void LLPanelObject::onCancelSculpt(const LLSD& data) if(mSculptTextureRevert == LLUUID::null) { - mSculptTextureRevert = LLUUID(SCULPT_DEFAULT_TEXTURE); + mSculptTextureRevert = SCULPT_DEFAULT_TEXTURE; } mTextureCtrl->setImageAssetID(mSculptTextureRevert); @@ -2269,7 +2269,7 @@ void LLPanelObject::onCopyParams() } else { - mClipboardParams["sculpt"]["id"] = LLUUID(SCULPT_DEFAULT_TEXTURE); + mClipboardParams["sculpt"]["id"] = SCULPT_DEFAULT_TEXTURE; } mClipboardParams["sculpt"]["type"] = sculpt_params->getSculptType(); diff --git a/indra/newview/lltexturectrl.cpp b/indra/newview/lltexturectrl.cpp index 0ce82a1297..0a95f58c4d 100644 --- a/indra/newview/lltexturectrl.cpp +++ b/indra/newview/lltexturectrl.cpp @@ -86,10 +86,10 @@ static const S32 LOCAL_TRACKING_ID_COLUMN = 1; //static bool get_is_predefined_texture(LLUUID asset_id) { - if (asset_id == LLUUID(gSavedSettings.getString("DefaultObjectTexture")) - || asset_id == LLUUID(gSavedSettings.getString("UIImgWhiteUUID")) - || asset_id == LLUUID(gSavedSettings.getString("UIImgInvisibleUUID")) - || asset_id == LLUUID(SCULPT_DEFAULT_TEXTURE)) + if (asset_id == DEFAULT_OBJECT_TEXTURE + || asset_id == UI_IMAGE_WHITE + || asset_id == UI_IMAGE_INVISIBLE + || asset_id == SCULPT_DEFAULT_TEXTURE) { return true; } @@ -1225,8 +1225,7 @@ LLTextureCtrl::LLTextureCtrl(const LLTextureCtrl::Params& p) // Default of defaults is white image for diff tex // - LLUUID whiteImage( gSavedSettings.getString( "UIImgWhiteUUID" ) ); - setBlankImageAssetID( whiteImage ); + setBlankImageAssetID(UI_IMAGE_WHITE); setAllowNoTexture(p.allow_no_texture); setCanApplyImmediately(p.can_apply_immediately); diff --git a/indra/newview/lltexturectrl.h b/indra/newview/lltexturectrl.h index fbb38c4464..a3952a62d6 100644 --- a/indra/newview/lltexturectrl.h +++ b/indra/newview/lltexturectrl.h @@ -63,6 +63,13 @@ bool get_is_predefined_texture(LLUUID asset_id); LLUUID get_copy_free_item_by_asset_id(LLUUID image_id, bool no_trans_perm = false); bool get_can_copy_texture(LLUUID image_id); +const LLUUID DEFAULT_BLANK_NORMAL_TEXTURE("5b53359e-59dd-d8a2-04c3-9e65134da47a"); +const LLUUID DEFAULT_OBJECT_NORMAL_TEXTURE("85f28839-7a1c-b4e3-d71d-967792970a7b"); +const LLUUID DEFAULT_OBJECT_SPECULAR_TEXTURE("87e0e8f7-8729-1ea8-cfc9-8915773009db"); +const LLUUID DEFAULT_OBJECT_TEXTURE("89556747-24cb-43ed-920b-47caed15465f"); +const LLUUID UI_IMAGE_WHITE("5748decc-f629-461c-9a36-a35a221fe21f"); +const LLUUID UI_IMAGE_INVISIBLE("89556747-24cb-43ed-920b-47caed15465f"); + ////////////////////////////////////////////////////////////////////////////////////////// // LLTextureCtrl diff --git a/indra/newview/lltoastalertpanel.cpp b/indra/newview/lltoastalertpanel.cpp index 692e8d91a9..7e68995a02 100644 --- a/indra/newview/lltoastalertpanel.cpp +++ b/indra/newview/lltoastalertpanel.cpp @@ -492,10 +492,9 @@ void LLToastAlertPanel::draw() } static LLUIColor shadow_color = LLUIColorTable::instance().getColor("ColorDropShadow"); - static LLUICachedControl shadow_lines ("DropShadowFloater", 5); gl_drop_shadow( 0, LLToastPanel::getRect().getHeight(), LLToastPanel::getRect().getWidth(), 0, - shadow_color, shadow_lines); + shadow_color, DROP_SHADOW_FLOATER); LLToastPanel::draw(); } diff --git a/indra/newview/lltooldraganddrop.cpp b/indra/newview/lltooldraganddrop.cpp index b16b26b96e..17bb316190 100644 --- a/indra/newview/lltooldraganddrop.cpp +++ b/indra/newview/lltooldraganddrop.cpp @@ -298,12 +298,10 @@ void LLToolDragAndDrop::setDragStart(S32 x, S32 y) BOOL LLToolDragAndDrop::isOverThreshold(S32 x,S32 y) { - static LLCachedControl drag_and_drop_threshold(gSavedSettings,"DragAndDropDistanceThreshold", 3); - S32 mouse_delta_x = x - mDragStartX; S32 mouse_delta_y = y - mDragStartY; - return (mouse_delta_x * mouse_delta_x) + (mouse_delta_y * mouse_delta_y) > drag_and_drop_threshold * drag_and_drop_threshold; + return (mouse_delta_x * mouse_delta_x) + (mouse_delta_y * mouse_delta_y) > DRAG_N_DROP_DISTANCE_THRESHOLD * DRAG_N_DROP_DISTANCE_THRESHOLD; } void LLToolDragAndDrop::beginDrag(EDragAndDropType type, @@ -566,12 +564,13 @@ BOOL LLToolDragAndDrop::handleKey(KEY key, MASK mask) BOOL LLToolDragAndDrop::handleToolTip(S32 x, S32 y, MASK mask) { + const F32 DRAG_N_DROP_TOOLTIP_DELAY = 0.10000000149f; if (!mToolTipMsg.empty()) { LLToolTipMgr::instance().unblockToolTips(); LLToolTipMgr::instance().show(LLToolTip::Params() .message(mToolTipMsg) - .delay_time(gSavedSettings.getF32( "DragAndDropToolTipDelay" ))); + .delay_time(DRAG_N_DROP_TOOLTIP_DELAY)); return TRUE; } return FALSE; diff --git a/indra/newview/lltoolpie.cpp b/indra/newview/lltoolpie.cpp index 17a7ad9d01..d41003ea6e 100644 --- a/indra/newview/lltoolpie.cpp +++ b/indra/newview/lltoolpie.cpp @@ -765,8 +765,7 @@ BOOL LLToolPie::handleHover(S32 x, S32 y, MASK mask) { S32 delta_x = x - mMouseDownX; S32 delta_y = y - mMouseDownY; - S32 threshold = gSavedSettings.getS32("DragAndDropDistanceThreshold"); - if (delta_x * delta_x + delta_y * delta_y > threshold * threshold) + if (delta_x * delta_x + delta_y * delta_y > DRAG_N_DROP_DISTANCE_THRESHOLD * DRAG_N_DROP_DISTANCE_THRESHOLD) { startCameraSteering(); steerCameraWithMouse(x, y); diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp index 9384f36fd2..d68d0cd92c 100644 --- a/indra/newview/llviewerwindow.cpp +++ b/indra/newview/llviewerwindow.cpp @@ -3372,11 +3372,13 @@ void LLViewerWindow::updateUI() if (gLoggedInTime.getStarted()) { - if (gLoggedInTime.getElapsedTimeF32() > gSavedSettings.getF32("DestinationGuideHintTimeout")) + const F32 DESTINATION_GUIDE_HINT_TIMEOUT = 1200.f; + const F32 SIDE_PANEL_HINT_TIMEOUT = 300.f; + if (gLoggedInTime.getElapsedTimeF32() > DESTINATION_GUIDE_HINT_TIMEOUT) { LLFirstUse::notUsingDestinationGuide(); } - if (gLoggedInTime.getElapsedTimeF32() > gSavedSettings.getF32("SidePanelHintTimeout")) + if (gLoggedInTime.getElapsedTimeF32() > SIDE_PANEL_HINT_TIMEOUT) { LLFirstUse::notUsingSidePanel(); } diff --git a/indra/newview/skins/default/xui/en/floater_media_browser.xml b/indra/newview/skins/default/xui/en/floater_media_browser.xml index ce788654aa..19b3c3160c 100644 --- a/indra/newview/skins/default/xui/en/floater_media_browser.xml +++ b/indra/newview/skins/default/xui/en/floater_media_browser.xml @@ -211,22 +211,12 @@ -