summaryrefslogtreecommitdiff
path: root/indra/newview/llpanelobjectinventory.cpp
diff options
context:
space:
mode:
authorOz Linden <oz@lindenlab.com>2015-08-17 16:00:04 -0400
committerOz Linden <oz@lindenlab.com>2015-08-17 16:00:04 -0400
commitfe2eefd9139a860cd9ffa67ee5f148ba3922320c (patch)
treed0395a805b44f525a5614bb2b3489d944555c170 /indra/newview/llpanelobjectinventory.cpp
parent4fb66604c9767bf518575963e9d4a871800bdeb3 (diff)
parent1be63209331d509396bd7ee79302d511fe83d72e (diff)
merge changes for 3.8.3-release
Diffstat (limited to 'indra/newview/llpanelobjectinventory.cpp')
-rwxr-xr-xindra/newview/llpanelobjectinventory.cpp12
1 files changed, 9 insertions, 3 deletions
diff --git a/indra/newview/llpanelobjectinventory.cpp b/indra/newview/llpanelobjectinventory.cpp
index bf15f56b44..c8af5b6718 100755
--- a/indra/newview/llpanelobjectinventory.cpp
+++ b/indra/newview/llpanelobjectinventory.cpp
@@ -130,7 +130,7 @@ public:
virtual void move(LLFolderViewModelItem* parent_listener);
virtual BOOL isItemCopyable() const;
virtual BOOL copyToClipboard() const;
- virtual BOOL cutToClipboard() const;
+ virtual BOOL cutToClipboard();
virtual BOOL isClipboardPasteable() const;
virtual void pasteFromClipboard();
virtual void pasteLinkFromClipboard();
@@ -542,7 +542,7 @@ BOOL LLTaskInvFVBridge::copyToClipboard() const
return FALSE;
}
-BOOL LLTaskInvFVBridge::cutToClipboard() const
+BOOL LLTaskInvFVBridge::cutToClipboard()
{
return FALSE;
}
@@ -1163,7 +1163,13 @@ void LLTaskNotecardBridge::openItem()
{
return;
}
- if(object->permModify() || gAgent.isGodlike())
+
+ // Note: even if we are not allowed to modify copyable notecard, we should be able to view it
+ LLInventoryItem *item = dynamic_cast<LLInventoryItem*>(object->getInventoryObject(mUUID));
+ BOOL item_copy = item && gAgent.allowOperation(PERM_COPY, item->getPermissions(), GP_OBJECT_MANIPULATE);
+ if( item_copy
+ || object->permModify()
+ || gAgent.isGodlike())
{
LLPreviewNotecard* preview = LLFloaterReg::showTypedInstance<LLPreviewNotecard>("preview_notecard", LLSD(mUUID), TAKE_FOCUS_YES);
if (preview)