diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/ClientStack/ClientView.cs | 1 | ||||
-rw-r--r-- | OpenSim/Region/Environment/Scenes/Scene.Inventory.cs | 53 | ||||
-rw-r--r-- | OpenSim/Region/Environment/Scenes/Scene.cs | 4 |
3 files changed, 54 insertions, 4 deletions
diff --git a/OpenSim/Region/ClientStack/ClientView.cs b/OpenSim/Region/ClientStack/ClientView.cs index dba3682..86591ec 100644 --- a/OpenSim/Region/ClientStack/ClientView.cs +++ b/OpenSim/Region/ClientStack/ClientView.cs | |||
@@ -3043,7 +3043,6 @@ namespace OpenSim.Region.ClientStack | |||
3043 | } | 3043 | } |
3044 | break; | 3044 | break; |
3045 | case PacketType.UpdateTaskInventory: | 3045 | case PacketType.UpdateTaskInventory: |
3046 | //Console.WriteLine(Pack.ToString()); | ||
3047 | UpdateTaskInventoryPacket updatetask = (UpdateTaskInventoryPacket) Pack; | 3046 | UpdateTaskInventoryPacket updatetask = (UpdateTaskInventoryPacket) Pack; |
3048 | if (OnUpdateTaskInventory != null) | 3047 | if (OnUpdateTaskInventory != null) |
3049 | { | 3048 | { |
diff --git a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs index 753d0cf..ceaadc2 100644 --- a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs +++ b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs | |||
@@ -357,7 +357,7 @@ namespace OpenSim.Region.Environment.Scenes | |||
357 | } | 357 | } |
358 | 358 | ||
359 | /// <summary> | 359 | /// <summary> |
360 | /// | 360 | /// Request a prim (task) inventory |
361 | /// </summary> | 361 | /// </summary> |
362 | /// <param name="remoteClient"></param> | 362 | /// <param name="remoteClient"></param> |
363 | /// <param name="primLocalID"></param> | 363 | /// <param name="primLocalID"></param> |
@@ -375,8 +375,19 @@ namespace OpenSim.Region.Environment.Scenes | |||
375 | } | 375 | } |
376 | } | 376 | } |
377 | } | 377 | } |
378 | else | ||
379 | { | ||
380 | MainLog.Instance.Warn( | ||
381 | "PRIMINVENTORY", "Inventory requested of prim {0} which doesn't exist", primLocalID); | ||
382 | } | ||
378 | } | 383 | } |
379 | 384 | ||
385 | /// <summary> | ||
386 | /// Remove an item from a prim (task) inventory | ||
387 | /// </summary> | ||
388 | /// <param name="remoteClient"></param> | ||
389 | /// <param name="itemID"></param> | ||
390 | /// <param name="localID"></param> | ||
380 | public void RemoveTaskInventory(IClientAPI remoteClient, LLUUID itemID, uint localID) | 391 | public void RemoveTaskInventory(IClientAPI remoteClient, LLUUID itemID, uint localID) |
381 | { | 392 | { |
382 | SceneObjectGroup group = GetGroupByPrim(localID); | 393 | SceneObjectGroup group = GetGroupByPrim(localID); |
@@ -389,6 +400,44 @@ namespace OpenSim.Region.Environment.Scenes | |||
389 | EventManager.TriggerRemoveScript(localID, itemID); | 400 | EventManager.TriggerRemoveScript(localID, itemID); |
390 | } | 401 | } |
391 | } | 402 | } |
403 | else | ||
404 | { | ||
405 | MainLog.Instance.Warn( | ||
406 | "PRIMINVENTORY", | ||
407 | "Removal of item {0} requested of prim {1} but this prim does not exist", | ||
408 | itemID, | ||
409 | localID); | ||
410 | } | ||
411 | } | ||
412 | |||
413 | /// <summary> | ||
414 | /// Update an item in a prim (task) inventory | ||
415 | /// </summary> | ||
416 | /// <param name="remoteClient"></param> | ||
417 | /// <param name="itemID"></param> | ||
418 | /// <param name="folderID"></param> | ||
419 | /// <param name="primLocalID"></param> | ||
420 | public void UpdateTaskInventory(IClientAPI remoteClient, LLUUID itemID, LLUUID folderID, | ||
421 | uint primLocalID) | ||
422 | { | ||
423 | SceneObjectGroup group = GetGroupByPrim(primLocalID); | ||
424 | if (group != null) | ||
425 | { | ||
426 | // TODO Retrieve itemID from client's inventory to pass on | ||
427 | //group.AddInventoryItem(rmoteClient, primLocalID, null); | ||
428 | MainLog.Instance.Verbose( | ||
429 | "PRIMINVENTORY", | ||
430 | "UpdateTaskInventory called with item {0}, folder {1}, primLocalID {2}", | ||
431 | itemID, folderID, primLocalID); | ||
432 | } | ||
433 | else | ||
434 | { | ||
435 | MainLog.Instance.Warn( | ||
436 | "PRIMINVENTORY", | ||
437 | "Update with item {0} requested of prim {1} but this prim does not exist", | ||
438 | itemID, | ||
439 | primLocalID); | ||
440 | } | ||
392 | } | 441 | } |
393 | 442 | ||
394 | public void RezScript(IClientAPI remoteClient, LLUUID itemID, uint localID) | 443 | public void RezScript(IClientAPI remoteClient, LLUUID itemID, uint localID) |
@@ -430,7 +479,7 @@ namespace OpenSim.Region.Environment.Scenes | |||
430 | if (group != null) | 479 | if (group != null) |
431 | { | 480 | { |
432 | // TODO: do we care about the value of this bool? | 481 | // TODO: do we care about the value of this bool? |
433 | bool added = group.AddInventoryItem(remoteClient, localID, item, copyID); | 482 | group.AddInventoryItem(remoteClient, localID, item, copyID); |
434 | group.GetProperites(remoteClient); | 483 | group.GetProperites(remoteClient); |
435 | } | 484 | } |
436 | } | 485 | } |
diff --git a/OpenSim/Region/Environment/Scenes/Scene.cs b/OpenSim/Region/Environment/Scenes/Scene.cs index c4b409f..79803a5 100644 --- a/OpenSim/Region/Environment/Scenes/Scene.cs +++ b/OpenSim/Region/Environment/Scenes/Scene.cs | |||
@@ -1149,7 +1149,6 @@ namespace OpenSim.Region.Environment.Scenes | |||
1149 | client.OnMoveInventoryFolder += CommsManager.UserProfileCacheService.HandleMoveInventoryFolder; | 1149 | client.OnMoveInventoryFolder += CommsManager.UserProfileCacheService.HandleMoveInventoryFolder; |
1150 | client.OnFetchInventoryDescendents += CommsManager.UserProfileCacheService.HandleFetchInventoryDescendents; | 1150 | client.OnFetchInventoryDescendents += CommsManager.UserProfileCacheService.HandleFetchInventoryDescendents; |
1151 | client.OnPurgeInventoryDescendents += CommsManager.UserProfileCacheService.HandlePurgeInventoryDescendents; | 1151 | client.OnPurgeInventoryDescendents += CommsManager.UserProfileCacheService.HandlePurgeInventoryDescendents; |
1152 | client.OnRequestTaskInventory += RequestTaskInventory; | ||
1153 | client.OnFetchInventory += CommsManager.UserProfileCacheService.HandleFetchInventory; | 1152 | client.OnFetchInventory += CommsManager.UserProfileCacheService.HandleFetchInventory; |
1154 | client.OnUpdateInventoryItem += UpdateInventoryItemAsset; | 1153 | client.OnUpdateInventoryItem += UpdateInventoryItemAsset; |
1155 | client.OnCopyInventoryItem += CopyInventoryItem; | 1154 | client.OnCopyInventoryItem += CopyInventoryItem; |
@@ -1157,7 +1156,10 @@ namespace OpenSim.Region.Environment.Scenes | |||
1157 | client.OnAssetUploadRequest += CommsManager.TransactionsManager.HandleUDPUploadRequest; | 1156 | client.OnAssetUploadRequest += CommsManager.TransactionsManager.HandleUDPUploadRequest; |
1158 | client.OnXferReceive += CommsManager.TransactionsManager.HandleXfer; | 1157 | client.OnXferReceive += CommsManager.TransactionsManager.HandleXfer; |
1159 | client.OnRezScript += RezScript; | 1158 | client.OnRezScript += RezScript; |
1159 | |||
1160 | client.OnRequestTaskInventory += RequestTaskInventory; | ||
1160 | client.OnRemoveTaskItem += RemoveTaskInventory; | 1161 | client.OnRemoveTaskItem += RemoveTaskInventory; |
1162 | client.OnUpdateTaskInventory += UpdateTaskInventory; | ||
1161 | 1163 | ||
1162 | client.OnGrabObject += ProcessObjectGrab; | 1164 | client.OnGrabObject += ProcessObjectGrab; |
1163 | client.OnAvatarPickerRequest += ProcessAvatarPickerRequest; | 1165 | client.OnAvatarPickerRequest += ProcessAvatarPickerRequest; |