summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorMerov Linden <merov@lindenlab.com>2014-12-22 16:33:47 -0800
committerMerov Linden <merov@lindenlab.com>2014-12-22 16:33:47 -0800
commite8ea398e123be29227275e8ca5b1d2d0ce7f1e4f (patch)
tree0e05274270a8b922aabe6fda792cc2a37c2014c8 /indra/newview
parentb0f590f6ab4033503ff9d80e2374e374397d40fb (diff)
DD-282 : Suppress Unassociate menu item. Confirm when cutting, deleting or moving a listing
Diffstat (limited to 'indra/newview')
-rwxr-xr-xindra/newview/llinventorybridge.cpp9
-rwxr-xr-xindra/newview/llinventoryfunctions.cpp6
-rwxr-xr-xindra/newview/skins/default/xui/en/menu_inventory.xml8
-rwxr-xr-xindra/newview/skins/default/xui/en/notifications.xml13
4 files changed, 25 insertions, 11 deletions
diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp
index 62612c1450..1f1017d78e 100755
--- a/indra/newview/llinventorybridge.cpp
+++ b/indra/newview/llinventorybridge.cpp
@@ -887,7 +887,6 @@ void LLInvFVBridge::addMarketplaceContextMenuOptions(U32 flags,
// Options available at the Listing Folder level
items.push_back(std::string("Marketplace Create Listing"));
items.push_back(std::string("Marketplace Associate Listing"));
- items.push_back(std::string("Marketplace Disassociate Listing"));
items.push_back(std::string("Marketplace List"));
items.push_back(std::string("Marketplace Unlist"));
if (LLMarketplaceData::instance().isUpdating(mUUID))
@@ -895,7 +894,6 @@ void LLInvFVBridge::addMarketplaceContextMenuOptions(U32 flags,
// During SLM update, disable all marketplace related options
disabled_items.push_back(std::string("Marketplace Create Listing"));
disabled_items.push_back(std::string("Marketplace Associate Listing"));
- disabled_items.push_back(std::string("Marketplace Disassociate Listing"));
disabled_items.push_back(std::string("Marketplace List"));
disabled_items.push_back(std::string("Marketplace Unlist"));
}
@@ -928,7 +926,6 @@ void LLInvFVBridge::addMarketplaceContextMenuOptions(U32 flags,
}
else
{
- disabled_items.push_back(std::string("Marketplace Disassociate Listing"));
disabled_items.push_back(std::string("Marketplace List"));
disabled_items.push_back(std::string("Marketplace Unlist"));
if (gSavedSettings.getBOOL("MarketplaceListingsLogging"))
@@ -2585,6 +2582,12 @@ BOOL LLFolderBridge::dragCategoryIntoFolder(LLInventoryCategory* inv_cat,
LLNotificationsUtil::add("ConfirmMerchantActiveChange", LLSD(), LLSD(), boost::bind(&LLFolderBridge::callback_dropCategoryIntoFolder, this, _1, _2, inv_cat));
return true;
}
+ if (move_is_from_marketplacelistings && LLMarketplaceData::instance().isListed(cat_id))
+ {
+ // Moving a whole listing folder will result in archival of SLM data. Ask confirmation.
+ LLNotificationsUtil::add("ConfirmListingCutOrDelete", LLSD(), LLSD(), boost::bind(&LLFolderBridge::callback_dropCategoryIntoFolder, this, _1, _2, inv_cat));
+ return true;
+ }
}
// Look for any gestures and deactivate them
if (move_is_into_trash)
diff --git a/indra/newview/llinventoryfunctions.cpp b/indra/newview/llinventoryfunctions.cpp
index ddcaf9d2bd..1a75ebbbac 100755
--- a/indra/newview/llinventoryfunctions.cpp
+++ b/indra/newview/llinventoryfunctions.cpp
@@ -2194,6 +2194,12 @@ void LLInventoryAction::doToSelected(LLInventoryModel* model, LLFolderView* root
LLNotificationsUtil::add("ConfirmMerchantActiveChange", LLSD(), LLSD(), boost::bind(&LLInventoryAction::callback_doToSelected, _1, _2, model, root, action));
return;
}
+ // Cutting or deleting a whole listing needs confirmation as SLM will be archived and inaccessible to the user
+ else if (LLMarketplaceData::instance().isListed(viewModel->getUUID()) && (("cut" == action) || ("delete" == action)))
+ {
+ LLNotificationsUtil::add("ConfirmListingCutOrDelete", LLSD(), LLSD(), boost::bind(&LLInventoryAction::callback_doToSelected, _1, _2, model, root, action));
+ return;
+ }
}
}
diff --git a/indra/newview/skins/default/xui/en/menu_inventory.xml b/indra/newview/skins/default/xui/en/menu_inventory.xml
index e28a02550f..63f408c05c 100755
--- a/indra/newview/skins/default/xui/en/menu_inventory.xml
+++ b/indra/newview/skins/default/xui/en/menu_inventory.xml
@@ -21,14 +21,6 @@
parameter="marketplace_associate_listing" />
</menu_item_call>
<menu_item_call
- label="Unassociate listing"
- layout="topleft"
- name="Marketplace Disassociate Listing">
- <menu_item_call.on_click
- function="Inventory.DoToSelected"
- parameter="marketplace_disassociate_listing" />
- </menu_item_call>
- <menu_item_call
label="Get (Refresh) listing"
layout="topleft"
name="Marketplace Get Listing">
diff --git a/indra/newview/skins/default/xui/en/notifications.xml b/indra/newview/skins/default/xui/en/notifications.xml
index 5b0bdc4a0d..4d856ed8a7 100755
--- a/indra/newview/skins/default/xui/en/notifications.xml
+++ b/indra/newview/skins/default/xui/en/notifications.xml
@@ -371,6 +371,19 @@ Initialization with the Marketplace failed because of a system or network error.
<notification
icon="alertmodal.tga"
+ name="ConfirmListingCutOrDelete"
+ type="alertmodal">
+ Moving or deleting a listing folder will delete your Marketplace listing. If you would like to keep the Marketplace listing, move or delete the contents of the version folder you would like to modify. Do you want to continue?
+ <tag>confirm</tag>
+ <usetemplate
+ ignoretext="Confirm before I move or delete a listing from the marketplace"
+ name="okcancelignore"
+ notext="Cancel"
+ yestext="OK"/>
+ </notification>
+
+ <notification
+ icon="alertmodal.tga"
name="ConfirmMerchantUnlist"
type="alertmodal">
This action will unlist this listing. Do you want to continue?