diff options
Diffstat (limited to 'OpenSim/Addons/Groups/GroupsMessagingModule.cs')
-rw-r--r-- | OpenSim/Addons/Groups/GroupsMessagingModule.cs | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/OpenSim/Addons/Groups/GroupsMessagingModule.cs b/OpenSim/Addons/Groups/GroupsMessagingModule.cs index 2ec9652..f4d3490 100644 --- a/OpenSim/Addons/Groups/GroupsMessagingModule.cs +++ b/OpenSim/Addons/Groups/GroupsMessagingModule.cs | |||
@@ -131,7 +131,7 @@ namespace OpenSim.Groups | |||
131 | { | 131 | { |
132 | if (!m_groupMessagingEnabled) | 132 | if (!m_groupMessagingEnabled) |
133 | return; | 133 | return; |
134 | 134 | ||
135 | scene.RegisterModuleInterface<IGroupsMessagingModule>(this); | 135 | scene.RegisterModuleInterface<IGroupsMessagingModule>(this); |
136 | m_sceneList.Add(scene); | 136 | m_sceneList.Add(scene); |
137 | 137 | ||
@@ -163,7 +163,7 @@ namespace OpenSim.Groups | |||
163 | if (m_groupData == null) | 163 | if (m_groupData == null) |
164 | { | 164 | { |
165 | m_log.Error("[Groups.Messaging]: Could not get IGroupsServicesConnector, GroupsMessagingModule is now disabled."); | 165 | m_log.Error("[Groups.Messaging]: Could not get IGroupsServicesConnector, GroupsMessagingModule is now disabled."); |
166 | RemoveRegion(scene); | 166 | RemoveRegion(scene); |
167 | return; | 167 | return; |
168 | } | 168 | } |
169 | 169 | ||
@@ -218,7 +218,7 @@ namespace OpenSim.Groups | |||
218 | m_msgTransferModule = null; | 218 | m_msgTransferModule = null; |
219 | } | 219 | } |
220 | 220 | ||
221 | public Type ReplaceableInterface | 221 | public Type ReplaceableInterface |
222 | { | 222 | { |
223 | get { return null; } | 223 | get { return null; } |
224 | } | 224 | } |
@@ -262,7 +262,7 @@ namespace OpenSim.Groups | |||
262 | { | 262 | { |
263 | if (m_debugEnabled) | 263 | if (m_debugEnabled) |
264 | m_log.DebugFormat("[Groups.Messaging]: {0} called", System.Reflection.MethodBase.GetCurrentMethod().Name); | 264 | m_log.DebugFormat("[Groups.Messaging]: {0} called", System.Reflection.MethodBase.GetCurrentMethod().Name); |
265 | 265 | ||
266 | GroupRecord groupInfo = m_groupData.GetGroupRecord(agentID.ToString(), groupID, null); | 266 | GroupRecord groupInfo = m_groupData.GetGroupRecord(agentID.ToString(), groupID, null); |
267 | 267 | ||
268 | if (groupInfo != null) | 268 | if (groupInfo != null) |
@@ -279,7 +279,7 @@ namespace OpenSim.Groups | |||
279 | { | 279 | { |
280 | SendMessageToGroup(im, groupID, UUID.Zero, null); | 280 | SendMessageToGroup(im, groupID, UUID.Zero, null); |
281 | } | 281 | } |
282 | 282 | ||
283 | public void SendMessageToGroup( | 283 | public void SendMessageToGroup( |
284 | GridInstantMessage im, UUID groupID, UUID sendingAgentForGroupCalls, Func<GroupMembersData, bool> sendCondition) | 284 | GridInstantMessage im, UUID groupID, UUID sendingAgentForGroupCalls, Func<GroupMembersData, bool> sendCondition) |
285 | { | 285 | { |
@@ -355,9 +355,9 @@ namespace OpenSim.Groups | |||
355 | { | 355 | { |
356 | if (!sendCondition(member)) | 356 | if (!sendCondition(member)) |
357 | { | 357 | { |
358 | if (m_debugEnabled) | 358 | if (m_debugEnabled) |
359 | m_log.DebugFormat( | 359 | m_log.DebugFormat( |
360 | "[Groups.Messaging]: Not sending to {0} as they do not fulfill send condition", | 360 | "[Groups.Messaging]: Not sending to {0} as they do not fulfill send condition", |
361 | member.AgentID); | 361 | member.AgentID); |
362 | 362 | ||
363 | continue; | 363 | continue; |
@@ -366,7 +366,7 @@ namespace OpenSim.Groups | |||
366 | else if (hasAgentDroppedGroupChatSession(member.AgentID.ToString(), groupID)) | 366 | else if (hasAgentDroppedGroupChatSession(member.AgentID.ToString(), groupID)) |
367 | { | 367 | { |
368 | // Don't deliver messages to people who have dropped this session | 368 | // Don't deliver messages to people who have dropped this session |
369 | if (m_debugEnabled) | 369 | if (m_debugEnabled) |
370 | m_log.DebugFormat("[Groups.Messaging]: {0} has dropped session, not delivering to them", member.AgentID); | 370 | m_log.DebugFormat("[Groups.Messaging]: {0} has dropped session, not delivering to them", member.AgentID); |
371 | 371 | ||
372 | continue; | 372 | continue; |
@@ -414,7 +414,7 @@ namespace OpenSim.Groups | |||
414 | "[Groups.Messaging]: SendMessageToGroup for group {0} with {1} visible members, {2} online took {3}ms", | 414 | "[Groups.Messaging]: SendMessageToGroup for group {0} with {1} visible members, {2} online took {3}ms", |
415 | groupID, groupMembersCount, groupMembers.Count(), Environment.TickCount - requestStartTick); | 415 | groupID, groupMembersCount, groupMembers.Count(), Environment.TickCount - requestStartTick); |
416 | } | 416 | } |
417 | 417 | ||
418 | #region SimGridEventHandlers | 418 | #region SimGridEventHandlers |
419 | 419 | ||
420 | void OnClientLogin(IClientAPI client) | 420 | void OnClientLogin(IClientAPI client) |
@@ -445,13 +445,13 @@ namespace OpenSim.Groups | |||
445 | // The instant message module will only deliver messages of dialog types: | 445 | // The instant message module will only deliver messages of dialog types: |
446 | // MessageFromAgent, StartTyping, StopTyping, MessageFromObject | 446 | // MessageFromAgent, StartTyping, StopTyping, MessageFromObject |
447 | // | 447 | // |
448 | // Any other message type will not be delivered to a client by the | 448 | // Any other message type will not be delivered to a client by the |
449 | // Instant Message Module | 449 | // Instant Message Module |
450 | 450 | ||
451 | UUID regionID = new UUID(msg.RegionID); | 451 | UUID regionID = new UUID(msg.RegionID); |
452 | if (m_debugEnabled) | 452 | if (m_debugEnabled) |
453 | { | 453 | { |
454 | m_log.DebugFormat("[Groups.Messaging]: {0} called, IM from region {1}", | 454 | m_log.DebugFormat("[Groups.Messaging]: {0} called, IM from region {1}", |
455 | System.Reflection.MethodBase.GetCurrentMethod().Name, regionID); | 455 | System.Reflection.MethodBase.GetCurrentMethod().Name, regionID); |
456 | 456 | ||
457 | DebugGridInstantMessage(msg); | 457 | DebugGridInstantMessage(msg); |
@@ -508,7 +508,7 @@ namespace OpenSim.Groups | |||
508 | m_log.DebugFormat("[Groups.Messaging]: skipping agent {0} because he has an agent in region of origin", sp.UUID); | 508 | m_log.DebugFormat("[Groups.Messaging]: skipping agent {0} because he has an agent in region of origin", sp.UUID); |
509 | return; | 509 | return; |
510 | } | 510 | } |
511 | else | 511 | else |
512 | { | 512 | { |
513 | if (m_debugEnabled) | 513 | if (m_debugEnabled) |
514 | m_log.DebugFormat("[Groups.Messaging]: not skipping agent {0}", sp.UUID); | 514 | m_log.DebugFormat("[Groups.Messaging]: not skipping agent {0}", sp.UUID); |
@@ -531,7 +531,7 @@ namespace OpenSim.Groups | |||
531 | } | 531 | } |
532 | } | 532 | } |
533 | }); | 533 | }); |
534 | 534 | ||
535 | } | 535 | } |
536 | } | 536 | } |
537 | } | 537 | } |
@@ -555,7 +555,7 @@ namespace OpenSim.Groups | |||
555 | break; | 555 | break; |
556 | 556 | ||
557 | case (byte)InstantMessageDialog.SessionSend: | 557 | case (byte)InstantMessageDialog.SessionSend: |
558 | // User hasn't dropped, so they're in the session, | 558 | // User hasn't dropped, so they're in the session, |
559 | // maybe we should deliver it. | 559 | // maybe we should deliver it. |
560 | IClientAPI client = GetActiveClient(new UUID(msg.toAgentID)); | 560 | IClientAPI client = GetActiveClient(new UUID(msg.toAgentID)); |
561 | if (client != null) | 561 | if (client != null) |
@@ -655,7 +655,7 @@ namespace OpenSim.Groups | |||
655 | UUID AgentID = new UUID(im.fromAgentID); | 655 | UUID AgentID = new UUID(im.fromAgentID); |
656 | 656 | ||
657 | GroupRecord groupInfo = m_groupData.GetGroupRecord(UUID.Zero.ToString(), GroupID, null); | 657 | GroupRecord groupInfo = m_groupData.GetGroupRecord(UUID.Zero.ToString(), GroupID, null); |
658 | 658 | ||
659 | if (groupInfo != null) | 659 | if (groupInfo != null) |
660 | { | 660 | { |
661 | AgentInvitedToGroupChatSession(AgentID.ToString(), GroupID); | 661 | AgentInvitedToGroupChatSession(AgentID.ToString(), GroupID); |
@@ -681,7 +681,7 @@ namespace OpenSim.Groups | |||
681 | UUID GroupID = new UUID(im.imSessionID); | 681 | UUID GroupID = new UUID(im.imSessionID); |
682 | UUID AgentID = new UUID(im.fromAgentID); | 682 | UUID AgentID = new UUID(im.fromAgentID); |
683 | 683 | ||
684 | if (m_debugEnabled) | 684 | if (m_debugEnabled) |
685 | m_log.DebugFormat("[Groups.Messaging]: Send message to session for group {0} with session ID {1}", GroupID, im.imSessionID.ToString()); | 685 | m_log.DebugFormat("[Groups.Messaging]: Send message to session for group {0} with session ID {1}", GroupID, im.imSessionID.ToString()); |
686 | 686 | ||
687 | //If this agent is sending a message, then they want to be in the session | 687 | //If this agent is sending a message, then they want to be in the session |