gAgent.set/getInventoryRootID() changed to gInventory.set/getRootFolderID()

This commit is contained in:
Shyotl
2011-10-12 02:29:12 -05:00
parent cfd154d46d
commit 36e0f667d5
22 changed files with 121 additions and 104 deletions

View File

@@ -320,7 +320,7 @@ BOOL LLInvFVBridge::isItemRemovable()
{
return TRUE;
}
if(model->isObjectDescendentOf(mUUID, gAgent.getInventoryRootID()))
if(model->isObjectDescendentOf(mUUID, gInventory.getRootFolderID()))
{
return TRUE;
}
@@ -937,8 +937,8 @@ BOOL LLInvFVBridge::isAgentInventory() const
{
const LLInventoryModel* model = getInventoryModel();
if(!model) return FALSE;
if(gAgent.getInventoryRootID() == mUUID) return TRUE;
return model->isObjectDescendentOf(mUUID, gAgent.getInventoryRootID());
if(gInventory.getRootFolderID() == mUUID) return TRUE;
return model->isObjectDescendentOf(mUUID, gInventory.getRootFolderID());
}
BOOL LLInvFVBridge::isCOFFolder() const
@@ -958,7 +958,7 @@ void LLInvFVBridge::changeItemParent(LLInventoryModel* model,
BOOL restamp)
{
// <edit>
bool send_parent_update = gInventory.isObjectDescendentOf(item->getUUID(), gAgent.getInventoryRootID());
bool send_parent_update = gInventory.isObjectDescendentOf(item->getUUID(), gInventory.getRootFolderID());
// </edit>
if(item->getParentUUID() != new_parent_id)
{
@@ -1635,11 +1635,11 @@ BOOL LLFolderBridge::isItemRemovable()
// <edit>
// People delete their inventory easily...
if(mUUID == gAgent.getInventoryRootID())
if(mUUID == gInventory.getRootFolderID())
{
return FALSE;
}
if(!model->isObjectDescendentOf(mUUID, gAgent.getInventoryRootID()))
if(!model->isObjectDescendentOf(mUUID, gInventory.getRootFolderID()))
{
return FALSE;
}
@@ -4035,7 +4035,7 @@ void LLObjectBridge::performAction(LLFolderView* folder, LLInventoryModel* model
LLUUID object_id = mUUID;
LLViewerInventoryItem* item;
item = (LLViewerInventoryItem*)gInventory.getItem(object_id);
if(item && gInventory.isObjectDescendentOf(object_id, gAgent.getInventoryRootID()))
if(item && gInventory.isObjectDescendentOf(object_id, gInventory.getRootFolderID()))
{
rez_attachment(item, NULL, replace);
}
@@ -4627,7 +4627,7 @@ void LLOutfitObserver::done()
}
if(pid.isNull())
{
pid = gAgent.getInventoryRootID();
pid = gInventory.getRootFolderID();
}
LLUUID cat_id = gInventory.createNewCategory(
@@ -4734,7 +4734,7 @@ void wear_outfit_by_name(const std::string& name)
LLInventoryModel::cat_array_t cat_array;
LLInventoryModel::item_array_t item_array;
LLNameCategoryCollector has_name(name);
gInventory.collectDescendentsIf(gAgent.getInventoryRootID(),
gInventory.collectDescendentsIf(gInventory.getRootFolderID(),
cat_array,
item_array,
LLInventoryModel::EXCLUDE_TRASH,