Start on Bulk inventory update via CAPS. Not functional yet. HG v2
parent
ccd7d35b3f
commit
37685ec1b4
|
@ -1,4 +1,4 @@
|
|||
The following people have contributed to OpenSim (Thank you
|
||||
<<<>>>>The following people have contributed to OpenSim (Thank you
|
||||
for your effort!)
|
||||
|
||||
= Current OpenSim Developers (in very rough order of appearance) =
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
|
||||
using System;
|
||||
using OpenMetaverse;
|
||||
using OpenSim.Framework;
|
||||
|
||||
namespace OpenSim.Framework.Client
|
||||
{
|
||||
|
@ -34,5 +35,6 @@ namespace OpenSim.Framework.Client
|
|||
{
|
||||
void SendRemoveInventoryFolders(UUID[] folders);
|
||||
void SendRemoveInventoryItems(UUID[] folders);
|
||||
void SendBulkUpdateInventory(InventoryFolderBase[] folders, InventoryItemBase[] items);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -12368,5 +12368,53 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
|||
eq.Enqueue(BuildEvent("RemoveInventoryFolder",
|
||||
llsd), AgentId);
|
||||
}
|
||||
|
||||
public void SendBulkUpdateInventory(InventoryFolderBase[] folders, InventoryItemBase[] items)
|
||||
{
|
||||
IEventQueue eq = Scene.RequestModuleInterface<IEventQueue>();
|
||||
|
||||
if (eq == null)
|
||||
{
|
||||
m_log.DebugFormat("[LLCLIENT]: Null event queue");
|
||||
return;
|
||||
}
|
||||
|
||||
OSDMap llsd = new OSDMap(3);
|
||||
|
||||
OSDMap AgentDataMap = new OSDMap(1);
|
||||
AgentDataMap.Add("AgentID", OSD.FromUUID(AgentId));
|
||||
AgentDataMap.Add("SessionID", OSD.FromUUID(SessionId));
|
||||
|
||||
OSDArray AgentData = new OSDArray(1);
|
||||
AgentData.Add(AgentDataMap);
|
||||
|
||||
llsd.Add("AgentData", AgentData);
|
||||
|
||||
OSDArray FolderData = new OSDArray();
|
||||
|
||||
foreach (UUID InventoryFolderBase in folders)
|
||||
{
|
||||
OSDMap FolderDataMap = new OSDMap(5);
|
||||
FolderDataMap.Add("FolderID", OSD.FromUUID(folder.ID));
|
||||
FolderDataMap.Add("AgentID", OSD.FromUUID(AgentId));
|
||||
FolderDataMap.Add("ParentID", OSD.FromUUID(folder.ParentID));
|
||||
FolderDataMap.Add("Type", OSD.FromInteger(folder.Type));
|
||||
FolderDataMap.Add("Name", OSD.FromString(folder.Name));
|
||||
|
||||
FolderData.Add(FolderDataMap);
|
||||
}
|
||||
|
||||
llsd.Add("FolderData", FolderData);
|
||||
|
||||
OSDArray ItemData = new OSDArray();
|
||||
|
||||
foreach (UUID InventoryItemBase in items)
|
||||
{
|
||||
OSDMap ItemDataMap = new OSDMap();
|
||||
ItemData.Add(DataMap);
|
||||
}
|
||||
|
||||
llsd.Add("ItemData", ItemData);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue