aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs
diff options
context:
space:
mode:
authorCharles Krinke2008-07-06 14:19:55 +0000
committerCharles Krinke2008-07-06 14:19:55 +0000
commit18c8bf99a49e998d1300368878e0e96e5a9b975e (patch)
tree0b0a12ba18d3a63ab61fa6b753d6abefe62f3a2a /OpenSim/Region/Environment/Scenes/Scene.Inventory.cs
parentCopyright notices and formatting cleanup. (diff)
downloadopensim-SC-18c8bf99a49e998d1300368878e0e96e5a9b975e.zip
opensim-SC-18c8bf99a49e998d1300368878e0e96e5a9b975e.tar.gz
opensim-SC-18c8bf99a49e998d1300368878e0e96e5a9b975e.tar.bz2
opensim-SC-18c8bf99a49e998d1300368878e0e96e5a9b975e.tar.xz
Mantis#1677. Thank you, Melanie for a patch that:
Patch propagates the permissionToTake flag into the timer handler, so that "take copy" and delete permissions are honored.
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/Scene.Inventory.cs')
-rw-r--r--OpenSim/Region/Environment/Scenes/Scene.Inventory.cs12
1 files changed, 8 insertions, 4 deletions
diff --git a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs
index d87b930..b479fed 100644
--- a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs
+++ b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs
@@ -46,6 +46,7 @@ namespace OpenSim.Region.Environment.Scenes
46 public IClientAPI remoteClient; 46 public IClientAPI remoteClient;
47 public SceneObjectGroup objectGroup; 47 public SceneObjectGroup objectGroup;
48 public LLUUID folderID; 48 public LLUUID folderID;
49 public bool permissionToDelete;
49 } 50 }
50 51
51 public partial class Scene 52 public partial class Scene
@@ -1505,6 +1506,7 @@ namespace OpenSim.Region.Environment.Scenes
1505 dtis.objectGroup = objectGroup; 1506 dtis.objectGroup = objectGroup;
1506 dtis.remoteClient = remoteClient; 1507 dtis.remoteClient = remoteClient;
1507 dtis.selectedEnt = selectedEnt; 1508 dtis.selectedEnt = selectedEnt;
1509 dtis.permissionToDelete = permissionToDelete;
1508 1510
1509 m_inventoryDeletes.Enqueue(dtis); 1511 m_inventoryDeletes.Enqueue(dtis);
1510 } 1512 }
@@ -1512,7 +1514,8 @@ namespace OpenSim.Region.Environment.Scenes
1512 m_inventoryTicker.Start(); 1514 m_inventoryTicker.Start();
1513 1515
1514 // Visually remove it, even if it isnt really gone yet. 1516 // Visually remove it, even if it isnt really gone yet.
1515 objectGroup.FakeDeleteGroup(); 1517 if (permissionToDelete)
1518 objectGroup.FakeDeleteGroup();
1516 } 1519 }
1517 else if (permissionToDelete) 1520 else if (permissionToDelete)
1518 { 1521 {
@@ -1543,7 +1546,7 @@ namespace OpenSim.Region.Environment.Scenes
1543 { 1546 {
1544 m_log.InfoFormat("Sending deleted object to user's inventory, {0} item(s) remaining.", left); 1547 m_log.InfoFormat("Sending deleted object to user's inventory, {0} item(s) remaining.", left);
1545 x = m_inventoryDeletes.Dequeue(); 1548 x = m_inventoryDeletes.Dequeue();
1546 DeleteToInventory(x.DeRezPacket, x.selectedEnt, x.remoteClient, x.objectGroup, x.folderID); 1549 DeleteToInventory(x.DeRezPacket, x.selectedEnt, x.remoteClient, x.objectGroup, x.folderID, x.permissionToDelete);
1547 return true; 1550 return true;
1548 } 1551 }
1549 } 1552 }
@@ -1556,7 +1559,7 @@ namespace OpenSim.Region.Environment.Scenes
1556 return false; 1559 return false;
1557 } 1560 }
1558 1561
1559 private void DeleteToInventory(DeRezObjectPacket DeRezPacket, EntityBase selectedEnt, IClientAPI remoteClient, SceneObjectGroup objectGroup, LLUUID folderID) 1562 private void DeleteToInventory(DeRezObjectPacket DeRezPacket, EntityBase selectedEnt, IClientAPI remoteClient, SceneObjectGroup objectGroup, LLUUID folderID, bool permissionToDelete)
1560 { 1563 {
1561 string sceneObjectXml = objectGroup.ToXmlString(); 1564 string sceneObjectXml = objectGroup.ToXmlString();
1562 1565
@@ -1662,7 +1665,8 @@ namespace OpenSim.Region.Environment.Scenes
1662 } 1665 }
1663 1666
1664 // Finally remove the item, for reals this time. 1667 // Finally remove the item, for reals this time.
1665 DeleteSceneObject(objectGroup); 1668 if(permissionToDelete)
1669 DeleteSceneObject(objectGroup);
1666 } 1670 }
1667 1671
1668 public void updateKnownAsset(IClientAPI remoteClient, SceneObjectGroup grp, LLUUID assetID, LLUUID agentID) 1672 public void updateKnownAsset(IClientAPI remoteClient, SceneObjectGroup grp, LLUUID assetID, LLUUID agentID)