aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ClientStack/LindenUDP
diff options
context:
space:
mode:
authordahlia2010-04-12 17:10:51 -0700
committerdahlia2010-04-12 17:10:51 -0700
commit3d0860ae616749518a40c6f6088d2644d589daf9 (patch)
tree0c4be75377265948201b742a342b078c4ece3609 /OpenSim/Region/ClientStack/LindenUDP
parentminor - add some documentation to PrimitiveBaseShape constructor with OpenMet... (diff)
downloadopensim-SC-3d0860ae616749518a40c6f6088d2644d589daf9.zip
opensim-SC-3d0860ae616749518a40c6f6088d2644d589daf9.tar.gz
opensim-SC-3d0860ae616749518a40c6f6088d2644d589daf9.tar.bz2
opensim-SC-3d0860ae616749518a40c6f6088d2644d589daf9.tar.xz
thanks lkalif for Mantis #4676 - a patch that adds support for inventory links
Signed-off-by: dahlia <dahliaTrimble@gmail.removeme.com>
Diffstat (limited to 'OpenSim/Region/ClientStack/LindenUDP')
-rw-r--r--OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs34
1 files changed, 34 insertions, 0 deletions
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
index 51ab281..f0f3932 100644
--- a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
+++ b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
@@ -182,6 +182,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
182 public event TeleportLocationRequest OnSetStartLocationRequest; 182 public event TeleportLocationRequest OnSetStartLocationRequest;
183 public event UpdateAvatarProperties OnUpdateAvatarProperties; 183 public event UpdateAvatarProperties OnUpdateAvatarProperties;
184 public event CreateNewInventoryItem OnCreateNewInventoryItem; 184 public event CreateNewInventoryItem OnCreateNewInventoryItem;
185 public event LinkInventoryItem OnLinkInventoryItem;
185 public event CreateInventoryFolder OnCreateNewInventoryFolder; 186 public event CreateInventoryFolder OnCreateNewInventoryFolder;
186 public event UpdateInventoryFolder OnUpdateInventoryFolder; 187 public event UpdateInventoryFolder OnUpdateInventoryFolder;
187 public event MoveInventoryFolder OnMoveInventoryFolder; 188 public event MoveInventoryFolder OnMoveInventoryFolder;
@@ -4749,6 +4750,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
4749 AddLocalPacketHandler(PacketType.UpdateInventoryFolder, HandleUpdateInventoryFolder); 4750 AddLocalPacketHandler(PacketType.UpdateInventoryFolder, HandleUpdateInventoryFolder);
4750 AddLocalPacketHandler(PacketType.MoveInventoryFolder, HandleMoveInventoryFolder); 4751 AddLocalPacketHandler(PacketType.MoveInventoryFolder, HandleMoveInventoryFolder);
4751 AddLocalPacketHandler(PacketType.CreateInventoryItem, HandleCreateInventoryItem); 4752 AddLocalPacketHandler(PacketType.CreateInventoryItem, HandleCreateInventoryItem);
4753 AddLocalPacketHandler(PacketType.LinkInventoryItem, HandleLinkInventoryItem);
4752 AddLocalPacketHandler(PacketType.FetchInventory, HandleFetchInventory); 4754 AddLocalPacketHandler(PacketType.FetchInventory, HandleFetchInventory);
4753 AddLocalPacketHandler(PacketType.FetchInventoryDescendents, HandleFetchInventoryDescendents); 4755 AddLocalPacketHandler(PacketType.FetchInventoryDescendents, HandleFetchInventoryDescendents);
4754 AddLocalPacketHandler(PacketType.PurgeInventoryDescendents, HandlePurgeInventoryDescendents); 4756 AddLocalPacketHandler(PacketType.PurgeInventoryDescendents, HandlePurgeInventoryDescendents);
@@ -7348,6 +7350,38 @@ namespace OpenSim.Region.ClientStack.LindenUDP
7348 return true; 7350 return true;
7349 } 7351 }
7350 7352
7353 private bool HandleLinkInventoryItem(IClientAPI sender, Packet Pack)
7354 {
7355 LinkInventoryItemPacket createLink = (LinkInventoryItemPacket)Pack;
7356
7357 #region Packet Session and User Check
7358 if (m_checkPackets)
7359 {
7360 if (createLink.AgentData.SessionID != SessionId ||
7361 createLink.AgentData.AgentID != AgentId)
7362 return true;
7363 }
7364 #endregion
7365
7366 LinkInventoryItem linkInventoryItem = OnLinkInventoryItem;
7367
7368 if (linkInventoryItem != null)
7369 {
7370 linkInventoryItem(
7371 this,
7372 createLink.InventoryBlock.TransactionID,
7373 createLink.InventoryBlock.FolderID,
7374 createLink.InventoryBlock.CallbackID,
7375 Util.FieldToString(createLink.InventoryBlock.Description),
7376 Util.FieldToString(createLink.InventoryBlock.Name),
7377 createLink.InventoryBlock.InvType,
7378 createLink.InventoryBlock.Type,
7379 createLink.InventoryBlock.OldItemID);
7380 }
7381
7382 return true;
7383 }
7384
7351 private bool HandleFetchInventory(IClientAPI sender, Packet Pack) 7385 private bool HandleFetchInventory(IClientAPI sender, Packet Pack)
7352 { 7386 {
7353 if (OnFetchInventory != null) 7387 if (OnFetchInventory != null)