diff options
author | Merov Linden <merov@lindenlab.com> | 2012-02-17 14:42:12 -0800 |
---|---|---|
committer | Merov Linden <merov@lindenlab.com> | 2012-02-17 14:42:12 -0800 |
commit | bb6ace0672fa5e1c47c534ba74396ef04daa408b (patch) | |
tree | 701f16864159f3777c29f27049b33066da2e8e3d /indra/newview | |
parent | 6363145f4556f3213f943637866445fae407593a (diff) |
EXP-1902, EXP-1903 : Move items cut to the trash when clipboard reset.
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/llfolderview.cpp | 5 | ||||
-rw-r--r-- | indra/newview/llfolderview.h | 2 | ||||
-rw-r--r-- | indra/newview/llinventorybridge.cpp | 2 |
3 files changed, 3 insertions, 6 deletions
diff --git a/indra/newview/llfolderview.cpp b/indra/newview/llfolderview.cpp index 0abfa9db8e..52cc70aee7 100644 --- a/indra/newview/llfolderview.cpp +++ b/indra/newview/llfolderview.cpp @@ -1014,6 +1014,7 @@ bool isDescendantOfASelectedItem(LLFolderViewItem* item, const std::vector<LLFol return false; } +// static void LLFolderView::removeCutItems() { // There's no item in "cut" mode on the clipboard -> exit @@ -2139,10 +2140,6 @@ bool LLFolderView::doToSelected(LLInventoryModel* model, const LLSD& userdata) } if (("copy" == action) || ("cut" == action)) { - // If there are things on the clipboard that have not been pasted but - // already disappeared from view, we need to move them to the trash - removeCutItems(); - // Clear the clipboard before we start adding things on it LLClipboard::getInstance()->reset(); } diff --git a/indra/newview/llfolderview.h b/indra/newview/llfolderview.h index 2f148d4e25..9a1df5a142 100644 --- a/indra/newview/llfolderview.h +++ b/indra/newview/llfolderview.h @@ -159,7 +159,7 @@ public: // deletion functionality void removeSelectedItems(); - void removeCutItems(); + static void removeCutItems(); // open the selected item. void openSelectedItems( void ); diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp index eb0f9803b0..54d195a2e6 100644 --- a/indra/newview/llinventorybridge.cpp +++ b/indra/newview/llinventorybridge.cpp @@ -213,7 +213,7 @@ BOOL LLInvFVBridge::cutToClipboard() const const LLInventoryObject* obj = gInventory.getObject(mUUID); if (obj && isItemMovable() && isItemRemovable()) { - LLClipboard::getInstance()->setCutMode(true); + LLClipboard::getInstance()->setCutMode(true, boost::bind(LLFolderView::removeCutItems)); return LLClipboard::getInstance()->addToClipboard(mUUID,obj->getType()); } return FALSE; |