summaryrefslogtreecommitdiff
path: root/indra/newview/llinventorybridge.cpp
diff options
context:
space:
mode:
authorandreykproductengine <akleshchev@productengine.com>2016-05-25 20:37:52 +0300
committerandreykproductengine <akleshchev@productengine.com>2016-05-25 20:37:52 +0300
commit7d54c62016c1362fc0f5fd69acda58c61aed5b76 (patch)
tree863cb1f875141f66dfa11fcfb81ee8e497ab0681 /indra/newview/llinventorybridge.cpp
parent757414afb892122a4aca6dd1d694b4fd6083a698 (diff)
MAINT-6397 cut items should not go to trash
Diffstat (limited to 'indra/newview/llinventorybridge.cpp')
-rw-r--r--indra/newview/llinventorybridge.cpp14
1 files changed, 11 insertions, 3 deletions
diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp
index 26c9b40fb1..f4bf38f65d 100644
--- a/indra/newview/llinventorybridge.cpp
+++ b/indra/newview/llinventorybridge.cpp
@@ -286,6 +286,16 @@ BOOL LLInvFVBridge::cutToClipboard()
return FALSE;
}
+// virtual
+bool LLInvFVBridge::isCutToClipboard()
+{
+ if (LLClipboard::instance().isCutMode())
+ {
+ return LLClipboard::instance().isOnClipboard(mUUID);
+ }
+ return false;
+}
+
// Callback for cutToClipboard if DAMA required...
BOOL LLInvFVBridge::callback_cutToClipboard(const LLSD& notification, const LLSD& response)
{
@@ -307,9 +317,7 @@ BOOL LLInvFVBridge::perform_cutToClipboard()
if (obj && isItemMovable() && isItemRemovable())
{
LLClipboard::instance().setCutMode(true);
- BOOL added_to_clipboard = LLClipboard::instance().addToClipboard(mUUID);
- removeObject(&gInventory, mUUID); // Always perform the remove even if the object couldn't make it to the clipboard
- return added_to_clipboard;
+ return LLClipboard::instance().addToClipboard(mUUID);
}
return FALSE;
}