From 0b3a4c75568a1648926c24463ed11cba53cfddb8 Mon Sep 17 00:00:00 2001 From: maxim_productengine Date: Tue, 28 Aug 2018 18:18:36 +0300 Subject: MAINT-8910 FIXED EEP - clicking at settings embedded into notecard does nothing --- indra/newview/llinventorybridge.cpp | 5 +++++ indra/newview/llviewertexteditor.cpp | 16 +++++++++++++++- indra/newview/llviewertexteditor.h | 1 + indra/newview/skins/default/xui/en/strings.xml | 1 + 4 files changed, 22 insertions(+), 1 deletion(-) (limited to 'indra/newview') diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp index 138ce9e1cf..e50055feb2 100644 --- a/indra/newview/llinventorybridge.cpp +++ b/indra/newview/llinventorybridge.cpp @@ -5097,6 +5097,11 @@ BOOL LLFolderBridge::dragItemIntoFolder(LLInventoryItem* inv_item, tooltip_msg = LLTrans::getString("TooltipOutboxNotInInventory"); accept = FALSE; } + else if ((inv_item->getActualType() == LLAssetType::AT_SETTINGS) && !LLEnvironment::instance().isInventoryEnabled()) + { + tooltip_msg = LLTrans::getString("NoEnvironmentSettings"); + accept = FALSE; + } else { // Don't allow placing an original item from a notecard to Current Outfit or an outfit folder diff --git a/indra/newview/llviewertexteditor.cpp b/indra/newview/llviewertexteditor.cpp index 714170a513..6899424cf6 100644 --- a/indra/newview/llviewertexteditor.cpp +++ b/indra/newview/llviewertexteditor.cpp @@ -1123,7 +1123,9 @@ BOOL LLViewerTextEditor::openEmbeddedItem(LLPointer item, llwch case LLAssetType::AT_CALLINGCARD: openEmbeddedCallingcard( item, wc ); return TRUE; - + case LLAssetType::AT_SETTINGS: + openEmbeddedSetting(item, wc); + return TRUE; case LLAssetType::AT_NOTECARD: case LLAssetType::AT_LSL_TEXT: case LLAssetType::AT_CLOTHING: @@ -1198,6 +1200,18 @@ void LLViewerTextEditor::openEmbeddedCallingcard( LLInventoryItem* item, llwchar } } +void LLViewerTextEditor::openEmbeddedSetting(LLInventoryItem* item, llwchar wc) +{ + if (LLEnvironment::instance().isInventoryEnabled()) + { + showCopyToInvDialog(item, wc); + } + else + { + LLNotificationsUtil::add("NoEnvironmentSettings"); + } +} + void LLViewerTextEditor::showUnsavedAlertDialog( LLInventoryItem* item ) { LLSD payload; diff --git a/indra/newview/llviewertexteditor.h b/indra/newview/llviewertexteditor.h index 44f104dde1..a6d7fef409 100644 --- a/indra/newview/llviewertexteditor.h +++ b/indra/newview/llviewertexteditor.h @@ -107,6 +107,7 @@ private: void openEmbeddedSound( LLInventoryItem* item, llwchar wc ); void openEmbeddedLandmark( LLPointer item_ptr, llwchar wc ); void openEmbeddedCallingcard( LLInventoryItem* item, llwchar wc); + void openEmbeddedSetting(LLInventoryItem* item, llwchar wc); void showCopyToInvDialog( LLInventoryItem* item, llwchar wc ); void showUnsavedAlertDialog( LLInventoryItem* item ); diff --git a/indra/newview/skins/default/xui/en/strings.xml b/indra/newview/skins/default/xui/en/strings.xml index c0481d1a28..3a882a73d3 100644 --- a/indra/newview/skins/default/xui/en/strings.xml +++ b/indra/newview/skins/default/xui/en/strings.xml @@ -2780,6 +2780,7 @@ If you continue to receive this message, please contact Second Life support for Local Settings Region Settings + This Region does not support environmental settings. Clicks: [TELEPORT] teleport, [MAP] map, [PROFILE] profile -- cgit v1.2.3