diff options
author | Melanie | 2013-05-13 02:15:48 +0200 |
---|---|---|
committer | Melanie | 2013-05-13 02:15:48 +0200 |
commit | 296b43f597e830c288ed0e56d1a6b78b955a7932 (patch) | |
tree | 4833c88606ad6605467f99892abdc5eaf10d417c | |
parent | Guard against trying to access terrain heights out of bounds. Clamp to sim. (diff) | |
download | opensim-SC_OLD-296b43f597e830c288ed0e56d1a6b78b955a7932.zip opensim-SC_OLD-296b43f597e830c288ed0e56d1a6b78b955a7932.tar.gz opensim-SC_OLD-296b43f597e830c288ed0e56d1a6b78b955a7932.tar.bz2 opensim-SC_OLD-296b43f597e830c288ed0e56d1a6b78b955a7932.tar.xz |
Small adjustments to the floater module
-rw-r--r-- | OpenSim/Region/Framework/Interfaces/IDynamicFloaterModule.cs | 2 | ||||
-rw-r--r-- | OpenSim/Region/OptionalModules/ViewerSupport/DynamicFloaterModule.cs | 5 |
2 files changed, 5 insertions, 2 deletions
diff --git a/OpenSim/Region/Framework/Interfaces/IDynamicFloaterModule.cs b/OpenSim/Region/Framework/Interfaces/IDynamicFloaterModule.cs index 65c42ff..7684ce3 100644 --- a/OpenSim/Region/Framework/Interfaces/IDynamicFloaterModule.cs +++ b/OpenSim/Region/Framework/Interfaces/IDynamicFloaterModule.cs | |||
@@ -37,7 +37,7 @@ namespace OpenSim.Region.Framework.Interfaces | |||
37 | public abstract class FloaterData | 37 | public abstract class FloaterData |
38 | { | 38 | { |
39 | public abstract int Channel { get; } | 39 | public abstract int Channel { get; } |
40 | public abstract string FloaterName { get; } | 40 | public abstract string FloaterName { get; set; } |
41 | public virtual string XmlName { get; set; } | 41 | public virtual string XmlName { get; set; } |
42 | public virtual string XmlText { get; set; } | 42 | public virtual string XmlText { get; set; } |
43 | public virtual HandlerDelegate Handler { get; set; } | 43 | public virtual HandlerDelegate Handler { get; set; } |
diff --git a/OpenSim/Region/OptionalModules/ViewerSupport/DynamicFloaterModule.cs b/OpenSim/Region/OptionalModules/ViewerSupport/DynamicFloaterModule.cs index 4524a05..e76e8f2 100644 --- a/OpenSim/Region/OptionalModules/ViewerSupport/DynamicFloaterModule.cs +++ b/OpenSim/Region/OptionalModules/ViewerSupport/DynamicFloaterModule.cs | |||
@@ -122,6 +122,9 @@ namespace OpenSim.Region.OptionalModules.ViewerSupport | |||
122 | if (!m_floaters.ContainsKey(agentID)) | 122 | if (!m_floaters.ContainsKey(agentID)) |
123 | m_floaters[agentID] = new Dictionary<int, FloaterData>(); | 123 | m_floaters[agentID] = new Dictionary<int, FloaterData>(); |
124 | 124 | ||
125 | if (m_floaters[agentID].ContainsKey(dialogData.Channel)) | ||
126 | return; | ||
127 | |||
125 | m_floaters[agentID].Add(dialogData.Channel, dialogData); | 128 | m_floaters[agentID].Add(dialogData.Channel, dialogData); |
126 | 129 | ||
127 | string xml; | 130 | string xml; |
@@ -218,7 +221,7 @@ namespace OpenSim.Region.OptionalModules.ViewerSupport | |||
218 | } | 221 | } |
219 | } | 222 | } |
220 | 223 | ||
221 | if (data.Handler(client, data, parts)) | 224 | if (data.Handler != null && data.Handler(client, data, parts)) |
222 | { | 225 | { |
223 | m_floaters[client.AgentId].Remove(data.Channel); | 226 | m_floaters[client.AgentId].Remove(data.Channel); |
224 | SendToClient(sp, String.Format("># floater {0} destroy", data.FloaterName)); | 227 | SendToClient(sp, String.Format("># floater {0} destroy", data.FloaterName)); |