diff options
Diffstat (limited to 'OpenSim/Region/OptionalModules/ViewerSupport/DynamicFloaterModule.cs')
-rw-r--r-- | OpenSim/Region/OptionalModules/ViewerSupport/DynamicFloaterModule.cs | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/OpenSim/Region/OptionalModules/ViewerSupport/DynamicFloaterModule.cs b/OpenSim/Region/OptionalModules/ViewerSupport/DynamicFloaterModule.cs index 7919fef..4524a05 100644 --- a/OpenSim/Region/OptionalModules/ViewerSupport/DynamicFloaterModule.cs +++ b/OpenSim/Region/OptionalModules/ViewerSupport/DynamicFloaterModule.cs | |||
@@ -125,10 +125,17 @@ namespace OpenSim.Region.OptionalModules.ViewerSupport | |||
125 | m_floaters[agentID].Add(dialogData.Channel, dialogData); | 125 | m_floaters[agentID].Add(dialogData.Channel, dialogData); |
126 | 126 | ||
127 | string xml; | 127 | string xml; |
128 | using (FileStream fs = File.Open(dialogData.XmlName + ".xml", FileMode.Open)) | 128 | if (dialogData.XmlText != null && dialogData.XmlText != String.Empty) |
129 | { | 129 | { |
130 | using (StreamReader sr = new StreamReader(fs)) | 130 | xml = dialogData.XmlText; |
131 | xml = sr.ReadToEnd().Replace("\n", ""); | 131 | } |
132 | else | ||
133 | { | ||
134 | using (FileStream fs = File.Open(dialogData.XmlName + ".xml", FileMode.Open)) | ||
135 | { | ||
136 | using (StreamReader sr = new StreamReader(fs)) | ||
137 | xml = sr.ReadToEnd().Replace("\n", ""); | ||
138 | } | ||
132 | } | 139 | } |
133 | 140 | ||
134 | List<string> xparts = new List<string>(); | 141 | List<string> xparts = new List<string>(); |