From 263fd1345875eb0389e2ed0a8cbeb4e458a2d007 Mon Sep 17 00:00:00 2001 From: Leslie Linden Date: Thu, 5 Jan 2012 10:57:09 -0800 Subject: Removed unused code for old outbox error reporting --- .../newview/llpanelmarketplaceoutboxinventory.cpp | 99 ++-------------------- 1 file changed, 5 insertions(+), 94 deletions(-) (limited to 'indra/newview/llpanelmarketplaceoutboxinventory.cpp') diff --git a/indra/newview/llpanelmarketplaceoutboxinventory.cpp b/indra/newview/llpanelmarketplaceoutboxinventory.cpp index ed1206aec8..1dd68b7758 100644 --- a/indra/newview/llpanelmarketplaceoutboxinventory.cpp +++ b/indra/newview/llpanelmarketplaceoutboxinventory.cpp @@ -46,50 +46,6 @@ static LLDefaultChildRegistry::Register r1("outbox_inven static LLDefaultChildRegistry::Register r2("outbox_folder_view_folder"); -// -// Marketplace errors -// - -enum -{ - MKTERR_NONE = 0, - - MKTERR_NOT_MERCHANT, - MKTERR_FOLDER_EMPTY, - MKTERR_UNASSOCIATED_PRODUCTS, - MKTERR_OBJECT_LIMIT, - MKTERR_FOLDER_DEPTH, - MKTERR_UNSELLABLE_ITEM, - MKTERR_INTERNAL_IMPORT, - - MKTERR_COUNT -}; - -static const std::string MARKETPLACE_ERROR_STRINGS[MKTERR_COUNT] = -{ - "NO_ERROR", - "NOT_MERCHANT_ERROR", - "FOLDER_EMPTY_ERROR", - "UNASSOCIATED_PRODUCTS_ERROR", - "OBJECT_LIMIT_ERROR", - "FOLDER_DEPTH_ERROR", - "UNSELLABLE_ITEM_FOUND", - "INTERNAL_IMPORT_ERROR", -}; - -static const std::string MARKETPLACE_ERROR_NAMES[MKTERR_COUNT] = -{ - "Marketplace Error None", - "Marketplace Error Not Merchant", - "Marketplace Error Empty Folder", - "Marketplace Error Unassociated Products", - "Marketplace Error Object Limit", - "Marketplace Error Folder Depth", - "Marketplace Error Unsellable Item", - "Marketplace Error Internal Import", -}; - - // // LLOutboxInventoryPanel Implementation // @@ -206,63 +162,18 @@ LLFolderViewItem * LLOutboxInventoryPanel::createFolderViewItem(LLInvFVBridge * LLOutboxFolderViewFolder::LLOutboxFolderViewFolder(const Params& p) : LLFolderViewFolder(p) - , LLBadgeOwner(getHandle()) - , mError(0) -{ - initBadgeParams(p.error_badge()); -} - -LLOutboxFolderViewFolder::~LLOutboxFolderViewFolder() { } -// virtual -void LLOutboxFolderViewFolder::draw() -{ - if (!badgeHasParent()) - { - addBadgeToParentPanel(); - } - - setBadgeVisibility(hasError()); - - LLFolderViewFolder::draw(); -} - -void LLOutboxFolderViewFolder::setErrorString(const std::string& errorString) -{ - S32 error_code = MKTERR_NONE; - - for (S32 i = 1; i < MKTERR_COUNT; ++i) - { - if (MARKETPLACE_ERROR_STRINGS[i] == errorString) - { - error_code = i; - break; - } - } - - setError(error_code); -} - -void LLOutboxFolderViewFolder::setError(S32 errorCode) -{ - mError = errorCode; - - if (hasError()) - { - setToolTip(LLTrans::getString(MARKETPLACE_ERROR_NAMES[mError])); - } - else - { - setToolTip(LLStringExplicit("")); - } -} - // // LLOutboxFolderViewItem Implementation // +LLOutboxFolderViewItem::LLOutboxFolderViewItem(const Params& p) + : LLFolderViewItem(p) +{ +} + BOOL LLOutboxFolderViewItem::handleDoubleClick(S32 x, S32 y, MASK mask) { return TRUE; -- cgit v1.2.3 From b0db21a8ae93283acc99491b9b14c2e8f1a35395 Mon Sep 17 00:00:00 2001 From: Leslie Linden Date: Thu, 5 Jan 2012 15:40:27 -0800 Subject: EXP-1754 FIX -- Search text shown in Outbox floater after marketplace synch if all items removed. * Added a setting to determine whether or not to display the standard empty inventory message. The message is on by default but turned off for the merchant outbox inventory panel. --- .../newview/llpanelmarketplaceoutboxinventory.cpp | 31 ---------------------- 1 file changed, 31 deletions(-) (limited to 'indra/newview/llpanelmarketplaceoutboxinventory.cpp') diff --git a/indra/newview/llpanelmarketplaceoutboxinventory.cpp b/indra/newview/llpanelmarketplaceoutboxinventory.cpp index 1dd68b7758..c14a0c8379 100644 --- a/indra/newview/llpanelmarketplaceoutboxinventory.cpp +++ b/indra/newview/llpanelmarketplaceoutboxinventory.cpp @@ -67,37 +67,6 @@ void LLOutboxInventoryPanel::buildFolderView(const LLInventoryPanel::Params& par LLUUID root_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_OUTBOX, false, false); - // leslie -- temporary HACK to work around sim not creating outbox with proper system folder type - if (root_id.isNull()) - { - std::string start_folder_name(params.start_folder()); - - LLInventoryModel::cat_array_t* cats; - LLInventoryModel::item_array_t* items; - - gInventory.getDirectDescendentsOf(gInventory.getRootFolderID(), cats, items); - - if (cats) - { - for (LLInventoryModel::cat_array_t::const_iterator cat_it = cats->begin(); cat_it != cats->end(); ++cat_it) - { - LLInventoryCategory* cat = *cat_it; - - if (cat->getName() == start_folder_name) - { - root_id = cat->getUUID(); - break; - } - } - } - - if (root_id == LLUUID::null) - { - llwarns << "No category found that matches outbox inventory panel start_folder: " << start_folder_name << llendl; - } - } - // leslie -- end temporary HACK - if (root_id == LLUUID::null) { llwarns << "Outbox inventory panel has no root folder!" << llendl; -- cgit v1.2.3 From 98f071aa6fc2961d9a86fa1d174c1f988a6ef8dc Mon Sep 17 00:00:00 2001 From: Leslie Linden Date: Wed, 11 Jan 2012 11:59:34 -0800 Subject: EXP-1790 FIX -- Hitting return on item in Merchant Outbox wears the object * Disabled the "openItem" function on outbox items to prevent default behavior when the return button is pressed. --- indra/newview/llpanelmarketplaceoutboxinventory.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'indra/newview/llpanelmarketplaceoutboxinventory.cpp') diff --git a/indra/newview/llpanelmarketplaceoutboxinventory.cpp b/indra/newview/llpanelmarketplaceoutboxinventory.cpp index c14a0c8379..ff62cb23db 100644 --- a/indra/newview/llpanelmarketplaceoutboxinventory.cpp +++ b/indra/newview/llpanelmarketplaceoutboxinventory.cpp @@ -148,4 +148,9 @@ BOOL LLOutboxFolderViewItem::handleDoubleClick(S32 x, S32 y, MASK mask) return TRUE; } +void LLOutboxFolderViewItem::openItem() +{ + // Intentionally do nothing to block attaching items from the outbox +} + // eof -- cgit v1.2.3