Only send dialogs and notices to root agents, not child agents

Small change for backport

Conflicts:

	OpenSim/Region/CoreModules/Avatar/Dialog/DialogModule.cs
0.6.9-post-fixes
Justin Clark-Casey (justincc) 2010-05-21 22:23:13 +01:00
parent e4114799c3
commit e589a31bc4
1 changed files with 5 additions and 5 deletions

View File

@ -79,7 +79,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Dialog
{ {
ScenePresence sp = m_scene.GetScenePresence(agentID); ScenePresence sp = m_scene.GetScenePresence(agentID);
if (sp != null) if (sp != null && !sp.IsChildAgent)
sp.ControllingClient.SendAgentAlertMessage(message, modal); sp.ControllingClient.SendAgentAlertMessage(message, modal);
} }
@ -91,7 +91,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Dialog
{ {
ScenePresence presence = presenceList[i]; ScenePresence presence = presenceList[i];
if (presence.Firstname == firstName && presence.Lastname == lastName) if (!presence.IsChildAgent && presence.Firstname == firstName && presence.Lastname == lastName)
{ {
presence.ControllingClient.SendAgentAlertMessage(message, modal); presence.ControllingClient.SendAgentAlertMessage(message, modal);
break; break;
@ -130,7 +130,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Dialog
} }
ScenePresence sp = m_scene.GetScenePresence(avatarID); ScenePresence sp = m_scene.GetScenePresence(avatarID);
if (sp != null) if (sp != null && !sp.IsChildAgent)
sp.ControllingClient.SendDialog(objectName, objectID, ownerFirstName, ownerLastName, message, textureID, ch, buttonlabels); sp.ControllingClient.SendDialog(objectName, objectID, ownerFirstName, ownerLastName, message, textureID, ch, buttonlabels);
} }
@ -139,7 +139,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Dialog
{ {
ScenePresence sp = m_scene.GetScenePresence(avatarID); ScenePresence sp = m_scene.GetScenePresence(avatarID);
if (sp != null) if (sp != null && !sp.IsChildAgent)
sp.ControllingClient.SendLoadURL(objectName, objectID, ownerID, groupOwned, message, url); sp.ControllingClient.SendLoadURL(objectName, objectID, ownerID, groupOwned, message, url);
} }
@ -206,4 +206,4 @@ namespace OpenSim.Region.CoreModules.Avatar.Dialog
return result; return result;
} }
} }
} }