summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indra/newview/llselectmgr.cpp11
-rw-r--r--indra/newview/llviewermenu.cpp1
-rw-r--r--indra/newview/skins/default/xui/en/menu_viewer.xml3
3 files changed, 12 insertions, 3 deletions
diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp
index 97c547e524..d2db6f6649 100644
--- a/indra/newview/llselectmgr.cpp
+++ b/indra/newview/llselectmgr.cpp
@@ -3891,6 +3891,17 @@ void LLSelectMgr::selectDuplicate(const LLVector3& offset, BOOL select_copy)
make_ui_sound("UISndInvalidOp");
return;
}
+ if (!canDuplicate())
+ {
+ LLSelectNode* node = getSelection()->getFirstRootNode(NULL, true);
+ if (node)
+ {
+ LLSD args;
+ args["OBJ_NAME"] = node->mName;
+ LLNotificationsUtil::add("NoCopyPermsNoObject", args);
+ return;
+ }
+ }
LLDuplicateData data;
data.offset = offset;
diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp
index aa6d75f5fb..8f7c0ee012 100644
--- a/indra/newview/llviewermenu.cpp
+++ b/indra/newview/llviewermenu.cpp
@@ -9205,7 +9205,6 @@ void initialize_menus()
enable.add("Object.EnableSit", boost::bind(&enable_object_sit, _1));
view_listener_t::addMenu(new LLObjectEnableReturn(), "Object.EnableReturn");
- enable.add("Object.EnableDuplicate", boost::bind(&LLSelectMgr::canDuplicate, LLSelectMgr::getInstance()));
view_listener_t::addMenu(new LLObjectEnableReportAbuse(), "Object.EnableReportAbuse");
enable.add("Avatar.EnableMute", boost::bind(&enable_object_mute));
diff --git a/indra/newview/skins/default/xui/en/menu_viewer.xml b/indra/newview/skins/default/xui/en/menu_viewer.xml
index cac84cfccf..9998f33c52 100644
--- a/indra/newview/skins/default/xui/en/menu_viewer.xml
+++ b/indra/newview/skins/default/xui/en/menu_viewer.xml
@@ -1051,8 +1051,7 @@
shortcut="control|D">
<menu_item_call.on_click
function="Object.Duplicate" />
- <menu_item_call.on_enable
- function="Object.EnableDuplicate" />
+
</menu_item_call>
</menu>
<menu