aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Services
diff options
context:
space:
mode:
authorJohn Hurliman2010-04-13 18:59:05 -0700
committerJohn Hurliman2010-04-13 18:59:05 -0700
commit6892fc41f71a00327336dec7158f3ce809ce32a4 (patch)
tree70c56d7d4eee22484055a84a980bbfe6679bc445 /OpenSim/Services
parentReduce number of AvatarAnimations sent with large number of avatars (diff)
downloadopensim-SC_OLD-6892fc41f71a00327336dec7158f3ce809ce32a4.zip
opensim-SC_OLD-6892fc41f71a00327336dec7158f3ce809ce32a4.tar.gz
opensim-SC_OLD-6892fc41f71a00327336dec7158f3ce809ce32a4.tar.bz2
opensim-SC_OLD-6892fc41f71a00327336dec7158f3ce809ce32a4.tar.xz
Applying patch from lkalif to add support for inventory links to the SimianGrid connectors
Diffstat (limited to 'OpenSim/Services')
-rw-r--r--OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs12
1 files changed, 12 insertions, 0 deletions
diff --git a/OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs b/OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs
index 56e7475..9005e94 100644
--- a/OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs
+++ b/OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs
@@ -583,6 +583,14 @@ namespace OpenSim.Services.Connectors.SimianGrid
583 { "Permissions", permissions } 583 { "Permissions", permissions }
584 }; 584 };
585 585
586 // Add different asset type only if it differs from inventory type
587 // (needed for links)
588 string invContentType = SLUtil.SLInvTypeToContentType(item.InvType);
589 string assetContentType = SLUtil.SLAssetTypeToContentType(item.AssetType);
590
591 if (invContentType != assetContentType)
592 extraData["LinkedItemType"] = OSD.FromString(assetContentType);
593
586 NameValueCollection requestArgs = new NameValueCollection 594 NameValueCollection requestArgs = new NameValueCollection
587 { 595 {
588 { "RequestMethod", "AddInventoryItem" }, 596 { "RequestMethod", "AddInventoryItem" },
@@ -593,6 +601,7 @@ namespace OpenSim.Services.Connectors.SimianGrid
593 { "Name", item.Name }, 601 { "Name", item.Name },
594 { "Description", item.Description }, 602 { "Description", item.Description },
595 { "CreatorID", item.CreatorId }, 603 { "CreatorID", item.CreatorId },
604 { "ContentType", invContentType },
596 { "ExtraData", OSDParser.SerializeJsonString(extraData) } 605 { "ExtraData", OSDParser.SerializeJsonString(extraData) }
597 }; 606 };
598 607
@@ -781,6 +790,9 @@ namespace OpenSim.Services.Connectors.SimianGrid
781 invItem.GroupPermissions = perms["GroupMask"].AsUInteger(); 790 invItem.GroupPermissions = perms["GroupMask"].AsUInteger();
782 invItem.NextPermissions = perms["NextOwnerMask"].AsUInteger(); 791 invItem.NextPermissions = perms["NextOwnerMask"].AsUInteger();
783 } 792 }
793
794 if (extraData.ContainsKey("LinkedItemType"))
795 invItem.AssetType = extraData["LinkedItemType"].AsInteger();
784 } 796 }
785 797
786 if (invItem.BasePermissions == 0) 798 if (invItem.BasePermissions == 0)