aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
authordahlia2009-11-13 22:13:40 -0800
committerdahlia2009-11-13 22:13:40 -0800
commit2e24415077ab4febf61e684fec8202a3a3e83b77 (patch)
tree8f6c8045b31a32780fdb789e051a38fc53224ea9 /OpenSim/Region
parentexpose SceneGraph.GetGroupByPrim(UUID) (diff)
downloadopensim-SC_OLD-2e24415077ab4febf61e684fec8202a3a3e83b77.zip
opensim-SC_OLD-2e24415077ab4febf61e684fec8202a3a3e83b77.tar.gz
opensim-SC_OLD-2e24415077ab4febf61e684fec8202a3a3e83b77.tar.bz2
opensim-SC_OLD-2e24415077ab4febf61e684fec8202a3a3e83b77.tar.xz
undo previous changes
add a GetGroupByPrim() method to Scene.cs delete a redundant method
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.Inventory.cs14
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.cs10
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneGraph.cs2
-rw-r--r--OpenSim/Region/Framework/Scenes/ScenePresence.cs2
4 files changed, 12 insertions, 16 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
index d790041..66fb918 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
@@ -803,20 +803,6 @@ namespace OpenSim.Region.Framework.Scenes
803 InventoryService.DeleteFolders(remoteClient.AgentId, folderIDs); 803 InventoryService.DeleteFolders(remoteClient.AgentId, folderIDs);
804 } 804 }
805 805
806 private SceneObjectGroup GetGroupByPrim(uint localID)
807 {
808 List<EntityBase> EntityList = GetEntities();
809
810 foreach (EntityBase ent in EntityList)
811 {
812 if (ent is SceneObjectGroup)
813 {
814 if (((SceneObjectGroup) ent).HasChildPrim(localID))
815 return (SceneObjectGroup) ent;
816 }
817 }
818 return null;
819 }
820 806
821 /// <summary> 807 /// <summary>
822 /// Send the details of a prim's inventory to the client. 808 /// Send the details of a prim's inventory to the client.
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs
index 4531e06..aeca7df 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.cs
@@ -4383,6 +4383,16 @@ namespace OpenSim.Region.Framework.Scenes
4383 return m_sceneGraph.GetSceneObjectPart(fullID); 4383 return m_sceneGraph.GetSceneObjectPart(fullID);
4384 } 4384 }
4385 4385
4386 /// <summary>
4387 /// Get a scene object group that contains the prim with the given local id
4388 /// </summary>
4389 /// <param name="localID"></param>
4390 /// <returns>null if no scene object group containing that prim is found</returns>
4391 public SceneObjectGroup GetGroupByPrim(uint localID)
4392 {
4393 return m_sceneGraph.GetGroupByPrim(localID);
4394 }
4395
4386 public bool TryGetAvatar(UUID avatarId, out ScenePresence avatar) 4396 public bool TryGetAvatar(UUID avatarId, out ScenePresence avatar)
4387 { 4397 {
4388 return m_sceneGraph.TryGetAvatar(avatarId, out avatar); 4398 return m_sceneGraph.TryGetAvatar(avatarId, out avatar);
diff --git a/OpenSim/Region/Framework/Scenes/SceneGraph.cs b/OpenSim/Region/Framework/Scenes/SceneGraph.cs
index 8ff441d..2fdb48d 100644
--- a/OpenSim/Region/Framework/Scenes/SceneGraph.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneGraph.cs
@@ -928,7 +928,7 @@ namespace OpenSim.Region.Framework.Scenes
928 /// </summary> 928 /// </summary>
929 /// <param name="fullID"></param> 929 /// <param name="fullID"></param>
930 /// <returns>null if no scene object group containing that prim is found</returns> 930 /// <returns>null if no scene object group containing that prim is found</returns>
931 public SceneObjectGroup GetGroupByPrim(UUID fullID) 931 private SceneObjectGroup GetGroupByPrim(UUID fullID)
932 { 932 {
933 SceneObjectGroup sog; 933 SceneObjectGroup sog;
934 lock (SceneObjectGroupsByFullID) 934 lock (SceneObjectGroupsByFullID)
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
index 17026e5..08c144a 100644
--- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs
+++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
@@ -3907,7 +3907,7 @@ namespace OpenSim.Region.Framework.Scenes
3907 } 3907 }
3908 else 3908 else
3909 { 3909 {
3910 group = Scene.SceneGraph.GetGroupByPrim(data.localID); 3910 group = Scene.GetGroupByPrim(data.localID);
3911 if (group != null) 3911 if (group != null)
3912 return GetSOGUpdatePriority(group); 3912 return GetSOGUpdatePriority(group);
3913 } 3913 }