From 0b743045ef38bbc38e80fe33944228bf2ca8c7e4 Mon Sep 17 00:00:00 2001 From: Michael Cerquoni Date: Wed, 23 Apr 2014 17:51:26 -0400 Subject: [PATCH 1/2] Add Dev Random to CONTRIBUTORS.txt, thanks for the patches! --- CONTRIBUTORS.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/CONTRIBUTORS.txt b/CONTRIBUTORS.txt index 1e87156ed6..f378925a89 100644 --- a/CONTRIBUTORS.txt +++ b/CONTRIBUTORS.txt @@ -80,6 +80,7 @@ what it is today. * ctrlaltdavid (David Rowe) * Daedius * daTwitch +* Dev Random * devalnor-#708 * dmiles (Daxtron Labs) * Dong Jun Lan (IBM) From 7180690a144dcb190b317ed28175c479c19c8a4a Mon Sep 17 00:00:00 2001 From: Dev Random Date: Sat, 19 Apr 2014 18:07:21 -0400 Subject: [PATCH 2/2] Show Group name when land is group-owned --- .../World/Land/LandManagementModule.cs | 35 +++++++++++++++---- 1 file changed, 28 insertions(+), 7 deletions(-) diff --git a/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs b/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs index fa5bfd67b9..ddea5b070c 100644 --- a/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs +++ b/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs @@ -75,7 +75,8 @@ namespace OpenSim.Region.CoreModules.World.Land private LandChannel landChannel; private Scene m_scene; - + + protected IGroupsModule m_groupManager; protected IUserManagement m_userManager; protected IPrimCountModule m_primCountModule; protected IDialogModule m_Dialog; @@ -150,9 +151,10 @@ namespace OpenSim.Region.CoreModules.World.Land public void RegionLoaded(Scene scene) { - m_userManager = m_scene.RequestModuleInterface(); - m_primCountModule = m_scene.RequestModuleInterface(); - m_Dialog = m_scene.RequestModuleInterface(); + m_userManager = m_scene.RequestModuleInterface(); + m_groupManager = m_scene.RequestModuleInterface(); + m_primCountModule = m_scene.RequestModuleInterface(); + m_Dialog = m_scene.RequestModuleInterface(); } public void RemoveRegion(Scene scene) @@ -2096,8 +2098,18 @@ namespace OpenSim.Region.CoreModules.World.Land foreach (ILandObject lo in m_landList.Values) { LandData ld = lo.LandData; + string ownerName; + if (ld.IsGroupOwned) + { + GroupRecord rec = m_groupManager.GetGroupRecord(ld.GroupID); + ownerName = (rec != null) ? rec.GroupName : "Unknown Group"; + } + else + { + ownerName = m_userManager.GetUserName(ld.OwnerID); + } cdt.AddRow( - ld.Name, ld.LocalID, ld.Area, lo.StartPoint, lo.EndPoint, m_userManager.GetUserName(ld.OwnerID)); + ld.Name, ld.LocalID, ld.Area, lo.StartPoint, lo.EndPoint, ownerName); } } @@ -2118,8 +2130,17 @@ namespace OpenSim.Region.CoreModules.World.Land cdl.AddRow("Ends", lo.EndPoint); cdl.AddRow("AABB Min", ld.AABBMin); cdl.AddRow("AABB Max", ld.AABBMax); - - cdl.AddRow("Owner", m_userManager.GetUserName(ld.OwnerID)); + string ownerName; + if (ld.IsGroupOwned) + { + GroupRecord rec = m_groupManager.GetGroupRecord(ld.GroupID); + ownerName = (rec != null) ? rec.GroupName : "Unknown Group"; + } + else + { + ownerName = m_userManager.GetUserName(ld.OwnerID); + } + cdl.AddRow("Owner", ownerName); cdl.AddRow("Is group owned?", ld.IsGroupOwned); cdl.AddRow("GroupID", ld.GroupID);