diff options
Diffstat (limited to 'OpenSim/Region/Framework')
-rw-r--r-- | OpenSim/Region/Framework/Interfaces/IEntityInventory.cs | 11 | ||||
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Animation/AnimationSet.cs | 4 | ||||
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Animation/DefaultAvatarAnimations.cs (renamed from OpenSim/Region/Framework/Scenes/Animation/AvatarAnimations.cs) | 4 | ||||
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Animation/ScenePresenceAnimator.cs | 4 | ||||
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Scene.Inventory.cs | 25 | ||||
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Scene.cs | 100 | ||||
-rw-r--r-- | OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs | 6 | ||||
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs | 6 |
8 files changed, 89 insertions, 71 deletions
diff --git a/OpenSim/Region/Framework/Interfaces/IEntityInventory.cs b/OpenSim/Region/Framework/Interfaces/IEntityInventory.cs index 15060fd..1334905 100644 --- a/OpenSim/Region/Framework/Interfaces/IEntityInventory.cs +++ b/OpenSim/Region/Framework/Interfaces/IEntityInventory.cs | |||
@@ -155,6 +155,15 @@ namespace OpenSim.Region.Framework.Interfaces | |||
155 | TaskInventoryItem GetInventoryItem(UUID itemId); | 155 | TaskInventoryItem GetInventoryItem(UUID itemId); |
156 | 156 | ||
157 | /// <summary> | 157 | /// <summary> |
158 | /// Get all inventory items. | ||
159 | /// </summary> | ||
160 | /// <param name="name"></param> | ||
161 | /// <returns> | ||
162 | /// If there are no inventory items then an empty list is returned. | ||
163 | /// </returns> | ||
164 | List<TaskInventoryItem> GetInventoryItems(); | ||
165 | |||
166 | /// <summary> | ||
158 | /// Get inventory items by name. | 167 | /// Get inventory items by name. |
159 | /// </summary> | 168 | /// </summary> |
160 | /// <param name="name"></param> | 169 | /// <param name="name"></param> |
@@ -162,7 +171,7 @@ namespace OpenSim.Region.Framework.Interfaces | |||
162 | /// A list of inventory items with that name. | 171 | /// A list of inventory items with that name. |
163 | /// If no inventory item has that name then an empty list is returned. | 172 | /// If no inventory item has that name then an empty list is returned. |
164 | /// </returns> | 173 | /// </returns> |
165 | IList<TaskInventoryItem> GetInventoryItems(string name); | 174 | List<TaskInventoryItem> GetInventoryItems(string name); |
166 | 175 | ||
167 | /// <summary> | 176 | /// <summary> |
168 | /// Get the scene object referenced by an inventory item. | 177 | /// Get the scene object referenced by an inventory item. |
diff --git a/OpenSim/Region/Framework/Scenes/Animation/AnimationSet.cs b/OpenSim/Region/Framework/Scenes/Animation/AnimationSet.cs index 240a424..33041e9 100644 --- a/OpenSim/Region/Framework/Scenes/Animation/AnimationSet.cs +++ b/OpenSim/Region/Framework/Scenes/Animation/AnimationSet.cs | |||
@@ -138,9 +138,9 @@ namespace OpenSim.Region.Framework.Scenes.Animation | |||
138 | // "[ANIMATION SET]: Setting default animation {0}, sequence number {1}, object id {2}", | 138 | // "[ANIMATION SET]: Setting default animation {0}, sequence number {1}, object id {2}", |
139 | // anim, sequenceNum, objectID); | 139 | // anim, sequenceNum, objectID); |
140 | 140 | ||
141 | if (AvatarAnimations.AnimsUUID.ContainsKey(anim)) | 141 | if (DefaultAvatarAnimations.AnimsUUID.ContainsKey(anim)) |
142 | { | 142 | { |
143 | return SetDefaultAnimation(AvatarAnimations.AnimsUUID[anim], sequenceNum, objectID); | 143 | return SetDefaultAnimation(DefaultAvatarAnimations.AnimsUUID[anim], sequenceNum, objectID); |
144 | } | 144 | } |
145 | return false; | 145 | return false; |
146 | } | 146 | } |
diff --git a/OpenSim/Region/Framework/Scenes/Animation/AvatarAnimations.cs b/OpenSim/Region/Framework/Scenes/Animation/DefaultAvatarAnimations.cs index ec928f4..c2b0468 100644 --- a/OpenSim/Region/Framework/Scenes/Animation/AvatarAnimations.cs +++ b/OpenSim/Region/Framework/Scenes/Animation/DefaultAvatarAnimations.cs | |||
@@ -33,7 +33,7 @@ using OpenMetaverse; | |||
33 | 33 | ||
34 | namespace OpenSim.Region.Framework.Scenes.Animation | 34 | namespace OpenSim.Region.Framework.Scenes.Animation |
35 | { | 35 | { |
36 | public class AvatarAnimations | 36 | public class DefaultAvatarAnimations |
37 | { | 37 | { |
38 | // private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 38 | // private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
39 | 39 | ||
@@ -43,7 +43,7 @@ namespace OpenSim.Region.Framework.Scenes.Animation | |||
43 | public static Dictionary<UUID, string> AnimsNames = new Dictionary<UUID, string>(); | 43 | public static Dictionary<UUID, string> AnimsNames = new Dictionary<UUID, string>(); |
44 | public static Dictionary<UUID, string> AnimStateNames = new Dictionary<UUID, string>(); | 44 | public static Dictionary<UUID, string> AnimStateNames = new Dictionary<UUID, string>(); |
45 | 45 | ||
46 | static AvatarAnimations() | 46 | static DefaultAvatarAnimations() |
47 | { | 47 | { |
48 | LoadAnimations(DefaultAnimationsPath); | 48 | LoadAnimations(DefaultAnimationsPath); |
49 | } | 49 | } |
diff --git a/OpenSim/Region/Framework/Scenes/Animation/ScenePresenceAnimator.cs b/OpenSim/Region/Framework/Scenes/Animation/ScenePresenceAnimator.cs index 9038ebc..f5623bd 100644 --- a/OpenSim/Region/Framework/Scenes/Animation/ScenePresenceAnimator.cs +++ b/OpenSim/Region/Framework/Scenes/Animation/ScenePresenceAnimator.cs | |||
@@ -99,7 +99,7 @@ namespace OpenSim.Region.Framework.Scenes.Animation | |||
99 | 99 | ||
100 | // XXX: For some reason, we store all animations and use them with upper case names, but in LSL animations | 100 | // XXX: For some reason, we store all animations and use them with upper case names, but in LSL animations |
101 | // are referenced with lower case names! | 101 | // are referenced with lower case names! |
102 | UUID animID = AvatarAnimations.GetDefaultAnimation(name.ToUpper()); | 102 | UUID animID = DefaultAvatarAnimations.GetDefaultAnimation(name.ToUpper()); |
103 | if (animID == UUID.Zero) | 103 | if (animID == UUID.Zero) |
104 | return; | 104 | return; |
105 | 105 | ||
@@ -125,7 +125,7 @@ namespace OpenSim.Region.Framework.Scenes.Animation | |||
125 | 125 | ||
126 | // XXX: For some reason, we store all animations and use them with upper case names, but in LSL animations | 126 | // XXX: For some reason, we store all animations and use them with upper case names, but in LSL animations |
127 | // are referenced with lower case names! | 127 | // are referenced with lower case names! |
128 | UUID animID = AvatarAnimations.GetDefaultAnimation(name); | 128 | UUID animID = DefaultAvatarAnimations.GetDefaultAnimation(name.ToUpper()); |
129 | if (animID == UUID.Zero) | 129 | if (animID == UUID.Zero) |
130 | return; | 130 | return; |
131 | 131 | ||
diff --git a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs index 6ae4adc..5abd74f 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs | |||
@@ -1210,9 +1210,9 @@ namespace OpenSim.Region.Framework.Scenes | |||
1210 | /// <summary> | 1210 | /// <summary> |
1211 | /// Copy a task (prim) inventory item to another task (prim) | 1211 | /// Copy a task (prim) inventory item to another task (prim) |
1212 | /// </summary> | 1212 | /// </summary> |
1213 | /// <param name="destId"></param> | 1213 | /// <param name="destId">ID of destination part</param> |
1214 | /// <param name="part"></param> | 1214 | /// <param name="part">Source part</param> |
1215 | /// <param name="itemId"></param> | 1215 | /// <param name="itemId">Source item id to transfer</param> |
1216 | public void MoveTaskInventoryItem(UUID destId, SceneObjectPart part, UUID itemId) | 1216 | public void MoveTaskInventoryItem(UUID destId, SceneObjectPart part, UUID itemId) |
1217 | { | 1217 | { |
1218 | TaskInventoryItem srcTaskItem = part.Inventory.GetInventoryItem(itemId); | 1218 | TaskInventoryItem srcTaskItem = part.Inventory.GetInventoryItem(itemId); |
@@ -1238,24 +1238,21 @@ namespace OpenSim.Region.Framework.Scenes | |||
1238 | return; | 1238 | return; |
1239 | } | 1239 | } |
1240 | 1240 | ||
1241 | // Can't transfer this | 1241 | if (part.OwnerID != destPart.OwnerID) |
1242 | // | ||
1243 | if ((part.OwnerID != destPart.OwnerID) && ((srcTaskItem.CurrentPermissions & (uint)PermissionMask.Transfer) == 0)) | ||
1244 | return; | ||
1245 | |||
1246 | if (part.OwnerID != destPart.OwnerID && (part.GetEffectiveObjectFlags() & (uint)PrimFlags.AllowInventoryDrop) == 0) | ||
1247 | { | 1242 | { |
1248 | // object cannot copy items to an object owned by a different owner | 1243 | // Source must have transfer permissions |
1249 | // unless llAllowInventoryDrop has been called | 1244 | if ((srcTaskItem.CurrentPermissions & (uint)PermissionMask.Transfer) == 0) |
1245 | return; | ||
1250 | 1246 | ||
1251 | return; | 1247 | // Object cannot copy items to an object owned by a different owner |
1248 | // unless llAllowInventoryDrop has been called on the destination | ||
1249 | if ((destPart.GetEffectiveObjectFlags() & (uint)PrimFlags.AllowInventoryDrop) == 0) | ||
1250 | return; | ||
1252 | } | 1251 | } |
1253 | 1252 | ||
1254 | // must have both move and modify permission to put an item in an object | 1253 | // must have both move and modify permission to put an item in an object |
1255 | if ((part.OwnerMask & ((uint)PermissionMask.Move | (uint)PermissionMask.Modify)) == 0) | 1254 | if ((part.OwnerMask & ((uint)PermissionMask.Move | (uint)PermissionMask.Modify)) == 0) |
1256 | { | ||
1257 | return; | 1255 | return; |
1258 | } | ||
1259 | 1256 | ||
1260 | TaskInventoryItem destTaskItem = new TaskInventoryItem(); | 1257 | TaskInventoryItem destTaskItem = new TaskInventoryItem(); |
1261 | 1258 | ||
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index 76e632e..d354ef0 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs | |||
@@ -211,14 +211,12 @@ namespace OpenSim.Region.Framework.Scenes | |||
211 | /// </summary> | 211 | /// </summary> |
212 | private bool m_cleaningTemps = false; | 212 | private bool m_cleaningTemps = false; |
213 | 213 | ||
214 | private Object m_heartbeatLock = new Object(); | 214 | // private Object m_heartbeatLock = new Object(); |
215 | 215 | ||
216 | // TODO: Possibly stop other classes being able to manipulate this directly. | 216 | // TODO: Possibly stop other classes being able to manipulate this directly. |
217 | private SceneGraph m_sceneGraph; | 217 | private SceneGraph m_sceneGraph; |
218 | private volatile int m_bordersLocked; | 218 | private volatile int m_bordersLocked; |
219 | // private int m_RestartTimerCounter; | ||
220 | private readonly Timer m_restartTimer = new Timer(15000); // Wait before firing | 219 | private readonly Timer m_restartTimer = new Timer(15000); // Wait before firing |
221 | // private int m_incrementsof15seconds; | ||
222 | private volatile bool m_backingup; | 220 | private volatile bool m_backingup; |
223 | private Dictionary<UUID, ReturnInfo> m_returns = new Dictionary<UUID, ReturnInfo>(); | 221 | private Dictionary<UUID, ReturnInfo> m_returns = new Dictionary<UUID, ReturnInfo>(); |
224 | private Dictionary<UUID, SceneObjectGroup> m_groupsWithTargets = new Dictionary<UUID, SceneObjectGroup>(); | 222 | private Dictionary<UUID, SceneObjectGroup> m_groupsWithTargets = new Dictionary<UUID, SceneObjectGroup>(); |
@@ -226,12 +224,17 @@ namespace OpenSim.Region.Framework.Scenes | |||
226 | private bool m_physics_enabled = true; | 224 | private bool m_physics_enabled = true; |
227 | private bool m_scripts_enabled = true; | 225 | private bool m_scripts_enabled = true; |
228 | private string m_defaultScriptEngine; | 226 | private string m_defaultScriptEngine; |
227 | |||
228 | /// <summary> | ||
229 | /// Tick at which the last login occurred. | ||
230 | /// </summary> | ||
229 | private int m_LastLogin; | 231 | private int m_LastLogin; |
232 | |||
230 | private Thread HeartbeatThread; | 233 | private Thread HeartbeatThread; |
231 | private volatile bool shuttingdown; | 234 | private volatile bool shuttingdown; |
232 | 235 | ||
233 | private int m_lastUpdate; | 236 | // private int m_lastUpdate; |
234 | private bool m_firstHeartbeat = true; | 237 | // private bool m_firstHeartbeat = true; |
235 | 238 | ||
236 | private UpdatePrioritizationSchemes m_priorityScheme = UpdatePrioritizationSchemes.Time; | 239 | private UpdatePrioritizationSchemes m_priorityScheme = UpdatePrioritizationSchemes.Time; |
237 | private bool m_reprioritizationEnabled = true; | 240 | private bool m_reprioritizationEnabled = true; |
@@ -801,7 +804,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
801 | 804 | ||
802 | m_permissions = new ScenePermissions(this); | 805 | m_permissions = new ScenePermissions(this); |
803 | 806 | ||
804 | m_lastUpdate = Util.EnvironmentTickCount(); | 807 | // m_lastUpdate = Util.EnvironmentTickCount(); |
805 | } | 808 | } |
806 | 809 | ||
807 | #endregion | 810 | #endregion |
@@ -1074,6 +1077,12 @@ namespace OpenSim.Region.Framework.Scenes | |||
1074 | m_physics_enabled = enablePhysics; | 1077 | m_physics_enabled = enablePhysics; |
1075 | } | 1078 | } |
1076 | 1079 | ||
1080 | // if (options.ContainsKey("collisions")) | ||
1081 | // { | ||
1082 | // // TODO: Implement. If false, should stop objects colliding, though possibly should still allow | ||
1083 | // // the avatar themselves to collide with the ground. | ||
1084 | // } | ||
1085 | |||
1077 | if (options.ContainsKey("teleport")) | 1086 | if (options.ContainsKey("teleport")) |
1078 | { | 1087 | { |
1079 | bool enableTeleportDebugging; | 1088 | bool enableTeleportDebugging; |
@@ -1150,9 +1159,9 @@ namespace OpenSim.Region.Framework.Scenes | |||
1150 | } | 1159 | } |
1151 | 1160 | ||
1152 | /// <summary> | 1161 | /// <summary> |
1153 | /// Start the timer which triggers regular scene updates | 1162 | /// Start the scene |
1154 | /// </summary> | 1163 | /// </summary> |
1155 | public void StartTimer() | 1164 | public void Start() |
1156 | { | 1165 | { |
1157 | // m_log.DebugFormat("[SCENE]: Starting Heartbeat timer for {0}", RegionInfo.RegionName); | 1166 | // m_log.DebugFormat("[SCENE]: Starting Heartbeat timer for {0}", RegionInfo.RegionName); |
1158 | 1167 | ||
@@ -1164,7 +1173,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
1164 | HeartbeatThread.Abort(); | 1173 | HeartbeatThread.Abort(); |
1165 | HeartbeatThread = null; | 1174 | HeartbeatThread = null; |
1166 | } | 1175 | } |
1167 | m_lastUpdate = Util.EnvironmentTickCount(); | 1176 | // m_lastUpdate = Util.EnvironmentTickCount(); |
1168 | 1177 | ||
1169 | HeartbeatThread | 1178 | HeartbeatThread |
1170 | = Watchdog.StartThread( | 1179 | = Watchdog.StartThread( |
@@ -1197,33 +1206,34 @@ namespace OpenSim.Region.Framework.Scenes | |||
1197 | /// </summary> | 1206 | /// </summary> |
1198 | private void Heartbeat() | 1207 | private void Heartbeat() |
1199 | { | 1208 | { |
1200 | if (!Monitor.TryEnter(m_heartbeatLock)) | 1209 | // if (!Monitor.TryEnter(m_heartbeatLock)) |
1201 | { | 1210 | // { |
1202 | Watchdog.RemoveThread(); | 1211 | // Watchdog.RemoveThread(); |
1203 | return; | 1212 | // return; |
1204 | } | 1213 | // } |
1205 | 1214 | ||
1206 | try | 1215 | // try |
1207 | { | 1216 | // { |
1208 | m_eventManager.TriggerOnRegionStarted(this); | ||
1209 | 1217 | ||
1210 | // The first frame can take a very long time due to physics actors being added on startup. Therefore, | 1218 | m_eventManager.TriggerOnRegionStarted(this); |
1211 | // don't turn on the watchdog alarm for this thread until the second frame, in order to prevent false | ||
1212 | // alarms for scenes with many objects. | ||
1213 | Update(1); | ||
1214 | Watchdog.GetCurrentThreadInfo().AlarmIfTimeout = true; | ||
1215 | 1219 | ||
1216 | while (!shuttingdown) | 1220 | // The first frame can take a very long time due to physics actors being added on startup. Therefore, |
1217 | Update(-1); | 1221 | // don't turn on the watchdog alarm for this thread until the second frame, in order to prevent false |
1222 | // alarms for scenes with many objects. | ||
1223 | Update(1); | ||
1224 | Watchdog.GetCurrentThreadInfo().AlarmIfTimeout = true; | ||
1218 | 1225 | ||
1219 | m_lastUpdate = Util.EnvironmentTickCount(); | 1226 | while (!shuttingdown) |
1220 | m_firstHeartbeat = false; | 1227 | Update(-1); |
1221 | } | 1228 | |
1222 | finally | 1229 | // m_lastUpdate = Util.EnvironmentTickCount(); |
1223 | { | 1230 | // m_firstHeartbeat = false; |
1224 | Monitor.Pulse(m_heartbeatLock); | 1231 | // } |
1225 | Monitor.Exit(m_heartbeatLock); | 1232 | // finally |
1226 | } | 1233 | // { |
1234 | // Monitor.Pulse(m_heartbeatLock); | ||
1235 | // Monitor.Exit(m_heartbeatLock); | ||
1236 | // } | ||
1227 | 1237 | ||
1228 | Watchdog.RemoveThread(); | 1238 | Watchdog.RemoveThread(); |
1229 | } | 1239 | } |
@@ -2535,7 +2545,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
2535 | = (aCircuit.teleportFlags & (uint)Constants.TeleportFlags.ViaHGLogin) != 0 | 2545 | = (aCircuit.teleportFlags & (uint)Constants.TeleportFlags.ViaHGLogin) != 0 |
2536 | || (aCircuit.teleportFlags & (uint)Constants.TeleportFlags.ViaLogin) != 0; | 2546 | || (aCircuit.teleportFlags & (uint)Constants.TeleportFlags.ViaLogin) != 0; |
2537 | 2547 | ||
2538 | CheckHeartbeat(); | 2548 | // CheckHeartbeat(); |
2539 | 2549 | ||
2540 | ScenePresence sp = GetScenePresence(client.AgentId); | 2550 | ScenePresence sp = GetScenePresence(client.AgentId); |
2541 | 2551 | ||
@@ -3111,7 +3121,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
3111 | 3121 | ||
3112 | public override void RemoveClient(UUID agentID, bool closeChildAgents) | 3122 | public override void RemoveClient(UUID agentID, bool closeChildAgents) |
3113 | { | 3123 | { |
3114 | CheckHeartbeat(); | 3124 | // CheckHeartbeat(); |
3115 | bool isChildAgent = false; | 3125 | bool isChildAgent = false; |
3116 | ScenePresence avatar = GetScenePresence(agentID); | 3126 | ScenePresence avatar = GetScenePresence(agentID); |
3117 | if (avatar != null) | 3127 | if (avatar != null) |
@@ -4498,8 +4508,8 @@ namespace OpenSim.Region.Framework.Scenes | |||
4498 | // | 4508 | // |
4499 | int health=1; // Start at 1, means we're up | 4509 | int health=1; // Start at 1, means we're up |
4500 | 4510 | ||
4501 | if ((Util.EnvironmentTickCountSubtract(m_lastUpdate)) < 1000) | 4511 | if ((Util.EnvironmentTickCountSubtract(m_lastFrameTick)) < 1000) |
4502 | health+=1; | 4512 | health += 1; |
4503 | else | 4513 | else |
4504 | return health; | 4514 | return health; |
4505 | 4515 | ||
@@ -4510,7 +4520,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
4510 | else | 4520 | else |
4511 | return health; | 4521 | return health; |
4512 | 4522 | ||
4513 | CheckHeartbeat(); | 4523 | // CheckHeartbeat(); |
4514 | 4524 | ||
4515 | return health; | 4525 | return health; |
4516 | } | 4526 | } |
@@ -4698,14 +4708,14 @@ namespace OpenSim.Region.Framework.Scenes | |||
4698 | return (((vsn.X * xdiff) + (vsn.Y * ydiff)) / (-1 * vsn.Z)) + p0.Z; | 4708 | return (((vsn.X * xdiff) + (vsn.Y * ydiff)) / (-1 * vsn.Z)) + p0.Z; |
4699 | } | 4709 | } |
4700 | 4710 | ||
4701 | private void CheckHeartbeat() | 4711 | // private void CheckHeartbeat() |
4702 | { | 4712 | // { |
4703 | if (m_firstHeartbeat) | 4713 | // if (m_firstHeartbeat) |
4704 | return; | 4714 | // return; |
4705 | 4715 | // | |
4706 | if (Util.EnvironmentTickCountSubtract(m_lastUpdate) > 2000) | 4716 | // if (Util.EnvironmentTickCountSubtract(m_lastFrameTick) > 2000) |
4707 | StartTimer(); | 4717 | // StartTimer(); |
4708 | } | 4718 | // } |
4709 | 4719 | ||
4710 | public override ISceneObject DeserializeObject(string representation) | 4720 | public override ISceneObject DeserializeObject(string representation) |
4711 | { | 4721 | { |
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs index f2d1915..71a9084 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectPartInventory.cs | |||
@@ -590,9 +590,9 @@ namespace OpenSim.Region.Framework.Scenes | |||
590 | /// A list of inventory items with that name. | 590 | /// A list of inventory items with that name. |
591 | /// If no inventory item has that name then an empty list is returned. | 591 | /// If no inventory item has that name then an empty list is returned. |
592 | /// </returns> | 592 | /// </returns> |
593 | public IList<TaskInventoryItem> GetInventoryItems(string name) | 593 | public List<TaskInventoryItem> GetInventoryItems(string name) |
594 | { | 594 | { |
595 | IList<TaskInventoryItem> items = new List<TaskInventoryItem>(); | 595 | List<TaskInventoryItem> items = new List<TaskInventoryItem>(); |
596 | 596 | ||
597 | lock (m_items) | 597 | lock (m_items) |
598 | { | 598 | { |
@@ -1100,7 +1100,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
1100 | 1100 | ||
1101 | public List<TaskInventoryItem> GetInventoryItems() | 1101 | public List<TaskInventoryItem> GetInventoryItems() |
1102 | { | 1102 | { |
1103 | List<TaskInventoryItem> ret = new List<TaskInventoryItem>(); | 1103 | List<TaskInventoryItem> ret = new List<TaskInventoryItem>(); |
1104 | 1104 | ||
1105 | lock (m_items) | 1105 | lock (m_items) |
1106 | ret = new List<TaskInventoryItem>(m_items.Values); | 1106 | ret = new List<TaskInventoryItem>(m_items.Values); |
diff --git a/OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs b/OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs index e16903c..55c80f5 100644 --- a/OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs +++ b/OpenSim/Region/Framework/Scenes/Tests/TaskInventoryTests.cs | |||
@@ -113,7 +113,7 @@ namespace OpenSim.Region.Framework.Tests | |||
113 | } | 113 | } |
114 | 114 | ||
115 | /// <summary> | 115 | /// <summary> |
116 | /// Test MoveTaskInventoryItem where the item has no parent folder assigned. | 116 | /// Test MoveTaskInventoryItem from a part inventory to a user inventory where the item has no parent folder assigned. |
117 | /// </summary> | 117 | /// </summary> |
118 | /// <remarks> | 118 | /// <remarks> |
119 | /// This should place it in the most suitable user folder. | 119 | /// This should place it in the most suitable user folder. |
@@ -142,9 +142,11 @@ namespace OpenSim.Region.Framework.Tests | |||
142 | } | 142 | } |
143 | 143 | ||
144 | /// <summary> | 144 | /// <summary> |
145 | /// Test MoveTaskInventoryItem where the item has no parent folder assigned. | 145 | /// Test MoveTaskInventoryItem from a part inventory to a user inventory where the item has no parent folder assigned. |
146 | /// </summary> | 146 | /// </summary> |
147 | /// <remarks> | ||
147 | /// This should place it in the most suitable user folder. | 148 | /// This should place it in the most suitable user folder. |
149 | /// </remarks> | ||
148 | [Test] | 150 | [Test] |
149 | public void TestMoveTaskInventoryItemNoParent() | 151 | public void TestMoveTaskInventoryItemNoParent() |
150 | { | 152 | { |