aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/CoreModules
diff options
context:
space:
mode:
authorMelanie Thielker2009-04-12 12:49:59 +0000
committerMelanie Thielker2009-04-12 12:49:59 +0000
commit87ce5ea0eb404386fd5e8b761e52c686db4a9d24 (patch)
treeca1a34a915160153fcb2e4e6a0862afd50cb1b6c /OpenSim/Region/CoreModules
parentFunnel stored (offline) IMs through the Scene EventManager to make sure (diff)
downloadopensim-SC_OLD-87ce5ea0eb404386fd5e8b761e52c686db4a9d24.zip
opensim-SC_OLD-87ce5ea0eb404386fd5e8b761e52c686db4a9d24.tar.gz
opensim-SC_OLD-87ce5ea0eb404386fd5e8b761e52c686db4a9d24.tar.bz2
opensim-SC_OLD-87ce5ea0eb404386fd5e8b761e52c686db4a9d24.tar.xz
Actually do what I promised in the previous commit :/
Diffstat (limited to 'OpenSim/Region/CoreModules')
-rw-r--r--OpenSim/Region/CoreModules/Avatar/InstantMessage/OfflineMessageModule.cs18
1 files changed, 14 insertions, 4 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/InstantMessage/OfflineMessageModule.cs b/OpenSim/Region/CoreModules/Avatar/InstantMessage/OfflineMessageModule.cs
index 09a75e2..a43834c 100644
--- a/OpenSim/Region/CoreModules/Avatar/InstantMessage/OfflineMessageModule.cs
+++ b/OpenSim/Region/CoreModules/Avatar/InstantMessage/OfflineMessageModule.cs
@@ -129,6 +129,17 @@ namespace OpenSim.Region.CoreModules.Avatar.InstantMessage
129 { 129 {
130 } 130 }
131 131
132 private Scene FindScene(UUID agentID)
133 {
134 foreach (Scene s in m_SceneList)
135 {
136 ScenePresence presence = s.GetScenePresence(agentID);
137 if (presence != null && !presence.IsChildAgent)
138 return s;
139 }
140 return null;
141 }
142
132 private IClientAPI FindClient(UUID agentID) 143 private IClientAPI FindClient(UUID agentID)
133 { 144 {
134 foreach (Scene s in m_SceneList) 145 foreach (Scene s in m_SceneList)
@@ -143,9 +154,6 @@ namespace OpenSim.Region.CoreModules.Avatar.InstantMessage
143 private void OnNewClient(IClientAPI client) 154 private void OnNewClient(IClientAPI client)
144 { 155 {
145 client.OnRetrieveInstantMessages += RetrieveInstantMessages; 156 client.OnRetrieveInstantMessages += RetrieveInstantMessages;
146 // TODO:: Remove when mute lists are supported
147 //
148 //client.OnEconomyDataRequest += OnEconomyDataRequest;
149 } 157 }
150 158
151 private void RetrieveInstantMessages(IClientAPI client) 159 private void RetrieveInstantMessages(IClientAPI client)
@@ -169,7 +177,9 @@ namespace OpenSim.Region.CoreModules.Avatar.InstantMessage
169 // Needed for proper state management for stored group 177 // Needed for proper state management for stored group
170 // invitations 178 // invitations
171 // 179 //
172 client.Scene.EventManager.TriggerIncomingInstantMessage(im); 180 Scene s = FindScene(client.AgentId);
181 if (s != null)
182 s.EventManager.TriggerIncomingInstantMessage(im);
173 } 183 }
174 } 184 }
175 185