diff options
author | Justin Clark-Casey (justincc) | 2012-03-30 00:40:19 +0100 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2012-03-30 00:42:55 +0100 |
commit | 59157d9d63c0e038ca0a619bfae1be3ed6f77677 (patch) | |
tree | 76e7ba7de91aedad887a6ac0633598d53ce30df3 /OpenSim/Region/CoreModules/World | |
parent | Merge branch 'master' of ssh://opensimulator.org/var/git/opensim (diff) | |
download | opensim-SC_OLD-59157d9d63c0e038ca0a619bfae1be3ed6f77677.zip opensim-SC_OLD-59157d9d63c0e038ca0a619bfae1be3ed6f77677.tar.gz opensim-SC_OLD-59157d9d63c0e038ca0a619bfae1be3ed6f77677.tar.bz2 opensim-SC_OLD-59157d9d63c0e038ca0a619bfae1be3ed6f77677.tar.xz |
Add simple login test with online friends. Add IFriendsModule.GrantRights() for granting rights via a module call.
Rename IFriendsModule.GetFriendPerms() -> GetRightsGrantedByFriend() to be more self-documenting and consistent with friends module terminology.
Add some method doc.
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs b/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs index ac03747..64759a7 100644 --- a/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs +++ b/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs | |||
@@ -487,7 +487,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions | |||
487 | return false; | 487 | return false; |
488 | } | 488 | } |
489 | 489 | ||
490 | protected bool IsFriendWithPerms(UUID user,UUID objectOwner) | 490 | protected bool IsFriendWithPerms(UUID user, UUID objectOwner) |
491 | { | 491 | { |
492 | if (user == UUID.Zero) | 492 | if (user == UUID.Zero) |
493 | return false; | 493 | return false; |
@@ -495,11 +495,8 @@ namespace OpenSim.Region.CoreModules.World.Permissions | |||
495 | if (m_friendsModule == null) | 495 | if (m_friendsModule == null) |
496 | return false; | 496 | return false; |
497 | 497 | ||
498 | uint friendPerms = m_friendsModule.GetFriendPerms(user, objectOwner); | 498 | int friendPerms = m_friendsModule.GetRightsGrantedByFriend(user, objectOwner); |
499 | if ((friendPerms & (uint)FriendRights.CanModifyObjects) != 0) | 499 | return (friendPerms & (int)FriendRights.CanModifyObjects) != 0; |
500 | return true; | ||
501 | |||
502 | return false; | ||
503 | } | 500 | } |
504 | 501 | ||
505 | protected bool IsEstateManager(UUID user) | 502 | protected bool IsEstateManager(UUID user) |
@@ -508,6 +505,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions | |||
508 | 505 | ||
509 | return m_scene.RegionInfo.EstateSettings.IsEstateManager(user); | 506 | return m_scene.RegionInfo.EstateSettings.IsEstateManager(user); |
510 | } | 507 | } |
508 | |||
511 | #endregion | 509 | #endregion |
512 | 510 | ||
513 | public bool PropagatePermissions() | 511 | public bool PropagatePermissions() |