aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Services/Friends
diff options
context:
space:
mode:
authorDiva Canto2011-05-19 16:54:46 -0700
committerDiva Canto2011-05-19 16:54:46 -0700
commitd21e9c755f004d8fe03b11bc57b810dbd401435a (patch)
tree1efd9e48308192d21ca73d8ff12d6a48c186077c /OpenSim/Services/Friends
parentAccidentally committed too early (diff)
downloadopensim-SC_OLD-d21e9c755f004d8fe03b11bc57b810dbd401435a.zip
opensim-SC_OLD-d21e9c755f004d8fe03b11bc57b810dbd401435a.tar.gz
opensim-SC_OLD-d21e9c755f004d8fe03b11bc57b810dbd401435a.tar.bz2
opensim-SC_OLD-d21e9c755f004d8fe03b11bc57b810dbd401435a.tar.xz
HG Friends working to some extent: friendships offered and accepted correctly handled. Friends list showing correct foreign names. TODO: GrantRights.
Diffstat (limited to 'OpenSim/Services/Friends')
-rw-r--r--OpenSim/Services/Friends/FriendsService.cs9
1 files changed, 4 insertions, 5 deletions
diff --git a/OpenSim/Services/Friends/FriendsService.cs b/OpenSim/Services/Friends/FriendsService.cs
index 3c64ecc..039dc0b 100644
--- a/OpenSim/Services/Friends/FriendsService.cs
+++ b/OpenSim/Services/Friends/FriendsService.cs
@@ -43,17 +43,16 @@ namespace OpenSim.Services.Friends
43 { 43 {
44 } 44 }
45 45
46 public FriendInfo[] GetFriends(UUID PrincipalID) 46 public virtual FriendInfo[] GetFriends(UUID PrincipalID)
47 { 47 {
48 FriendsData[] data = m_Database.GetFriends(PrincipalID); 48 FriendsData[] data = m_Database.GetFriends(PrincipalID);
49
50 List<FriendInfo> info = new List<FriendInfo>(); 49 List<FriendInfo> info = new List<FriendInfo>();
51 50
52 foreach (FriendsData d in data) 51 foreach (FriendsData d in data)
53 { 52 {
54 FriendInfo i = new FriendInfo(); 53 FriendInfo i = new FriendInfo();
55 54
56 i.PrincipalID = d.PrincipalID; 55 i.PrincipalID = new UUID(d.PrincipalID);
57 i.Friend = d.Friend; 56 i.Friend = d.Friend;
58 i.MyFlags = Convert.ToInt32(d.Data["Flags"]); 57 i.MyFlags = Convert.ToInt32(d.Data["Flags"]);
59 i.TheirFlags = Convert.ToInt32(d.Data["TheirFlags"]); 58 i.TheirFlags = Convert.ToInt32(d.Data["TheirFlags"]);
@@ -64,7 +63,7 @@ namespace OpenSim.Services.Friends
64 return info.ToArray(); 63 return info.ToArray();
65 } 64 }
66 65
67 public bool StoreFriend(UUID PrincipalID, string Friend, int flags) 66 public virtual bool StoreFriend(string PrincipalID, string Friend, int flags)
68 { 67 {
69 FriendsData d = new FriendsData(); 68 FriendsData d = new FriendsData();
70 69
@@ -76,7 +75,7 @@ namespace OpenSim.Services.Friends
76 return m_Database.Store(d); 75 return m_Database.Store(d);
77 } 76 }
78 77
79 public bool Delete(UUID PrincipalID, string Friend) 78 public virtual bool Delete(UUID PrincipalID, string Friend)
80 { 79 {
81 return m_Database.Delete(PrincipalID, Friend); 80 return m_Database.Delete(PrincipalID, Friend);
82 } 81 }