Small adjustments to the floater module
parent
3f6071ce3a
commit
296b43f597
|
@ -37,7 +37,7 @@ namespace OpenSim.Region.Framework.Interfaces
|
||||||
public abstract class FloaterData
|
public abstract class FloaterData
|
||||||
{
|
{
|
||||||
public abstract int Channel { get; }
|
public abstract int Channel { get; }
|
||||||
public abstract string FloaterName { get; }
|
public abstract string FloaterName { get; set; }
|
||||||
public virtual string XmlName { get; set; }
|
public virtual string XmlName { get; set; }
|
||||||
public virtual string XmlText { get; set; }
|
public virtual string XmlText { get; set; }
|
||||||
public virtual HandlerDelegate Handler { get; set; }
|
public virtual HandlerDelegate Handler { get; set; }
|
||||||
|
|
|
@ -122,6 +122,9 @@ namespace OpenSim.Region.OptionalModules.ViewerSupport
|
||||||
if (!m_floaters.ContainsKey(agentID))
|
if (!m_floaters.ContainsKey(agentID))
|
||||||
m_floaters[agentID] = new Dictionary<int, FloaterData>();
|
m_floaters[agentID] = new Dictionary<int, FloaterData>();
|
||||||
|
|
||||||
|
if (m_floaters[agentID].ContainsKey(dialogData.Channel))
|
||||||
|
return;
|
||||||
|
|
||||||
m_floaters[agentID].Add(dialogData.Channel, dialogData);
|
m_floaters[agentID].Add(dialogData.Channel, dialogData);
|
||||||
|
|
||||||
string xml;
|
string xml;
|
||||||
|
@ -218,7 +221,7 @@ namespace OpenSim.Region.OptionalModules.ViewerSupport
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (data.Handler(client, data, parts))
|
if (data.Handler != null && data.Handler(client, data, parts))
|
||||||
{
|
{
|
||||||
m_floaters[client.AgentId].Remove(data.Channel);
|
m_floaters[client.AgentId].Remove(data.Channel);
|
||||||
SendToClient(sp, String.Format("># floater {0} destroy", data.FloaterName));
|
SendToClient(sp, String.Format("># floater {0} destroy", data.FloaterName));
|
||||||
|
|
Loading…
Reference in New Issue