aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/Communications/Capabilities/LLSDHelpers.cs
diff options
context:
space:
mode:
authorMW2008-03-15 11:48:27 +0000
committerMW2008-03-15 11:48:27 +0000
commit70e55205a19ca83aa2f63c2b2c5d2c300e2324f6 (patch)
tree947d7bff36771428f0e6eb8bb8405dc3db247be3 /OpenSim/Framework/Communications/Capabilities/LLSDHelpers.cs
parent* Fix for Justincc's bug report #768 - Terrain looks rather phallic. (diff)
downloadopensim-SC-70e55205a19ca83aa2f63c2b2c5d2c300e2324f6.zip
opensim-SC-70e55205a19ca83aa2f63c2b2c5d2c300e2324f6.tar.gz
opensim-SC-70e55205a19ca83aa2f63c2b2c5d2c300e2324f6.tar.bz2
opensim-SC-70e55205a19ca83aa2f63c2b2c5d2c300e2324f6.tar.xz
Part 1 of making inventory work again in the 1.19.1 (RC) client. Implemented the FetchInventoryDescendents CAPS handler. But currently returning empty folder details.
So this commit doesn't actually fix inventory in that client, it just stops the "loading" message being displayed forever next to a folder, and instead shows empty folders. Next part will be to fill in the details of the items in the folders.
Diffstat (limited to 'OpenSim/Framework/Communications/Capabilities/LLSDHelpers.cs')
-rw-r--r--OpenSim/Framework/Communications/Capabilities/LLSDHelpers.cs12
1 files changed, 9 insertions, 3 deletions
diff --git a/OpenSim/Framework/Communications/Capabilities/LLSDHelpers.cs b/OpenSim/Framework/Communications/Capabilities/LLSDHelpers.cs
index 28f838d..193927d 100644
--- a/OpenSim/Framework/Communications/Capabilities/LLSDHelpers.cs
+++ b/OpenSim/Framework/Communications/Capabilities/LLSDHelpers.cs
@@ -66,14 +66,18 @@ namespace OpenSim.Region.Capabilities
66 if (fieldAttributes.Length > 0) 66 if (fieldAttributes.Length > 0)
67 { 67 {
68 writer.WriteStartElement(String.Empty, "key", String.Empty); 68 writer.WriteStartElement(String.Empty, "key", String.Empty);
69 writer.WriteString(fields[i].Name); 69 string fieldName = fields[i].Name;
70 fieldName = fieldName.Replace("___", "-");
71 writer.WriteString(fieldName);
70 writer.WriteEndElement(); 72 writer.WriteEndElement();
71 SerializeLLSDType(writer, fieldValue); 73 SerializeLLSDType(writer, fieldValue);
72 } 74 }
73 else 75 else
74 { 76 {
75 writer.WriteStartElement(String.Empty, "key", String.Empty); 77 writer.WriteStartElement(String.Empty, "key", String.Empty);
76 writer.WriteString(fields[i].Name); 78 string fieldName = fields[i].Name;
79 fieldName = fieldName.Replace("___", "-");
80 writer.WriteString(fieldName);
77 writer.WriteEndElement(); 81 writer.WriteEndElement();
78 LLSD.LLSDWriteOne(writer, fieldValue); 82 LLSD.LLSDWriteOne(writer, fieldValue);
79 // libsecondlife.StructuredData.LLSDParser.SerializeXmlElement( 83 // libsecondlife.StructuredData.LLSDParser.SerializeXmlElement(
@@ -118,7 +122,9 @@ namespace OpenSim.Region.Capabilities
118 IDictionaryEnumerator enumerator = llsd.GetEnumerator(); 122 IDictionaryEnumerator enumerator = llsd.GetEnumerator();
119 while (enumerator.MoveNext()) 123 while (enumerator.MoveNext())
120 { 124 {
121 FieldInfo field = myType.GetField((string) enumerator.Key); 125 string keyName = (string)enumerator.Key;
126 keyName = keyName.Replace("-","_");
127 FieldInfo field = myType.GetField(keyName);
122 if (field != null) 128 if (field != null)
123 { 129 {
124 // if (enumerator.Value is libsecondlife.StructuredData.LLSDMap) 130 // if (enumerator.Value is libsecondlife.StructuredData.LLSDMap)