diff options
author | Merov Linden <merov@lindenlab.com> | 2012-02-07 17:13:24 -0800 |
---|---|---|
committer | Merov Linden <merov@lindenlab.com> | 2012-02-07 17:13:24 -0800 |
commit | c744603af9b53c6bc73fefbd56de68cf2778ed70 (patch) | |
tree | 353cea8bbf89f69bd644b6d0b3fd2fa4c66acf8b /indra/llui | |
parent | 9761375ac244af36635899c73e99efc46b68b589 (diff) |
EXP-1873 : Implement cut in the inventory contextual menu. Works without deleting the items but simply dimming them and moving them. Doesn't work for folders yet.
Diffstat (limited to 'indra/llui')
-rw-r--r-- | indra/llui/llclipboard.cpp | 6 | ||||
-rw-r--r-- | indra/llui/llclipboard.h | 2 |
2 files changed, 8 insertions, 0 deletions
diff --git a/indra/llui/llclipboard.cpp b/indra/llui/llclipboard.cpp index 5c8db29ae4..a2a3f7f285 100644 --- a/indra/llui/llclipboard.cpp +++ b/indra/llui/llclipboard.cpp @@ -97,6 +97,12 @@ BOOL LLClipboard::hasContents() const return (mObjects.count() > 0); } +// Returns true if the input uuid is in the list of clipboard objects +bool LLClipboard::isOnClipboard(const LLUUID& object) const +{ + return (mObjects.find(object) != LLDynamicArray<LLUUID>::FAIL); +} + // Copy the input string to the LL and the system clipboard bool LLClipboard::copyToClipboard(const LLWString &src, S32 pos, S32 len, bool use_primary) { diff --git a/indra/llui/llclipboard.h b/indra/llui/llclipboard.h index bb2d003703..8e417a490d 100644 --- a/indra/llui/llclipboard.h +++ b/indra/llui/llclipboard.h @@ -69,6 +69,8 @@ public: BOOL hasContents() const; // true if the clipboard has something pasteable in it bool isCutMode() const { return mCutMode; } + void setCutMode(bool mode) { mCutMode = mode; } + bool isOnClipboard(const LLUUID& object) const; private: LLDynamicArray<LLUUID> mObjects; |