aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/Communications
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Framework/Communications')
-rw-r--r--OpenSim/Framework/Communications/Cache/LibraryRootFolder.cs19
1 files changed, 12 insertions, 7 deletions
diff --git a/OpenSim/Framework/Communications/Cache/LibraryRootFolder.cs b/OpenSim/Framework/Communications/Cache/LibraryRootFolder.cs
index 216e13f..7ff2c97 100644
--- a/OpenSim/Framework/Communications/Cache/LibraryRootFolder.cs
+++ b/OpenSim/Framework/Communications/Cache/LibraryRootFolder.cs
@@ -142,8 +142,10 @@ namespace OpenSim.Framework.Communications.Cache
142 item.avatarID = libOwner; 142 item.avatarID = libOwner;
143 item.creatorsID = libOwner; 143 item.creatorsID = libOwner;
144 item.inventoryID = 144 item.inventoryID =
145 new LLUUID(source.Configs[i].GetString("inventoryID", LLUUID.Random().ToString())); 145 new LLUUID(source.Configs[i].GetString("inventoryID", folderID.ToString()));
146 item.assetID = new LLUUID(source.Configs[i].GetString("assetID", LLUUID.Random().ToString())); 146 item.assetID = new LLUUID(source.Configs[i].GetString("assetID", LLUUID.Random().ToString()));
147 item.parentFolderID
148 = new LLUUID(source.Configs[i].GetString("folderID", LLUUID.Random().ToString()));
147 item.inventoryDescription = source.Configs[i].GetString("description", ""); 149 item.inventoryDescription = source.Configs[i].GetString("description", "");
148 item.inventoryName = source.Configs[i].GetString("name", ""); 150 item.inventoryName = source.Configs[i].GetString("name", "");
149 item.assetType = source.Configs[i].GetInt("assetType", 0); 151 item.assetType = source.Configs[i].GetInt("assetType", 0);
@@ -152,16 +154,19 @@ namespace OpenSim.Framework.Communications.Cache
152 item.inventoryNextPermissions = (uint) source.Configs[i].GetLong("nextPermissions", 0x7FFFFFFF); 154 item.inventoryNextPermissions = (uint) source.Configs[i].GetLong("nextPermissions", 0x7FFFFFFF);
153 item.inventoryEveryOnePermissions = (uint) source.Configs[i].GetLong("everyonePermissions", 0x7FFFFFFF); 155 item.inventoryEveryOnePermissions = (uint) source.Configs[i].GetLong("everyonePermissions", 0x7FFFFFFF);
154 item.inventoryBasePermissions = (uint) source.Configs[i].GetLong("basePermissions", 0x7FFFFFFF); 156 item.inventoryBasePermissions = (uint) source.Configs[i].GetLong("basePermissions", 0x7FFFFFFF);
155 if (item.assetType == 0) 157
158 if (item.parentFolderID == folderID)
156 { 159 {
157 item.parentFolderID = m_textureFolder.folderID; 160 Items.Add(item.inventoryID, item);
158 m_textureFolder.Items.Add(item.inventoryID, item);
159 } 161 }
160 else 162 else
161 { 163 {
162 item.parentFolderID = folderID; 164 // Very temporary - will only work for immediate child folders
163 Items.Add(item.inventoryID, item); 165 if (SubFolders.ContainsKey(item.parentFolderID))
164 } 166 {
167 SubFolders[item.parentFolderID].Items.Add(item.inventoryID, item);
168 }
169 }
165 } 170 }
166 } 171 }
167 } 172 }