diff options
Diffstat (limited to 'indra/newview')
-rwxr-xr-x | indra/newview/llinventorybridge.h | 6 | ||||
-rwxr-xr-x | indra/newview/llinventorypanel.cpp | 11 |
2 files changed, 16 insertions, 1 deletions
diff --git a/indra/newview/llinventorybridge.h b/indra/newview/llinventorybridge.h index 7dac830098..833fbbadbb 100755 --- a/indra/newview/llinventorybridge.h +++ b/indra/newview/llinventorybridge.h @@ -158,7 +158,7 @@ protected: BOOL isAgentInventory() const; // false if lost or in the inventory library BOOL isCOFFolder() const; // true if COF or descendant of BOOL isInboxFolder() const; // true if COF or descendant of marketplace inbox - BOOL isOutboxFolder() const; // true if COF or descendant of marketplace outbox + BOOL isOutboxFolderDirectParent() const; const LLUUID getOutboxFolder() const; @@ -172,6 +172,10 @@ protected: const LLUUID& new_parent, BOOL restamp); void removeBatchNoCheck(std::vector<LLFolderViewModelItem*>& batch); + +public: + BOOL isOutboxFolder() const; // true if COF or descendant of marketplace outbox + protected: LLHandle<LLInventoryPanel> mInventoryPanel; LLFolderView* mRoot; diff --git a/indra/newview/llinventorypanel.cpp b/indra/newview/llinventorypanel.cpp index 4cb724e9c4..adfdfebae7 100755 --- a/indra/newview/llinventorypanel.cpp +++ b/indra/newview/llinventorypanel.cpp @@ -1403,6 +1403,17 @@ BOOL LLInventoryPanel::handleKeyHere( KEY key, MASK mask ) // Open selected items if enter key hit on the inventory panel if (mask == MASK_NONE) { + //Don't allow attaching or opening items from Merchant Outbox + LLFolderViewItem* folder_item = mFolderRoot.get()->getCurSelectedItem(); + if(folder_item) + { + LLInvFVBridge* bridge = (LLInvFVBridge*)folder_item->getViewModelItem(); + if(bridge && bridge->isOutboxFolder() && (bridge->getInventoryType() != LLInventoryType::IT_CATEGORY)) + { + return handled; + } + } + LLInventoryAction::doToSelected(mInventory, mFolderRoot.get(), "open"); handled = TRUE; } |