corrade-vassal

Subversion Repositories:
Compare Path: Rev
With Path: Rev
?path1? @ 22  →  ?path2? @ 21
/Vassal/Vassal/VassalConfiguration.cs
@@ -8,6 +8,7 @@
using System.Collections.Generic;
using System.ComponentModel;
using System.IO;
using System.Linq;
using System.Text;
using System.Xml.Serialization;
 
@@ -41,6 +42,7 @@
public class VassalConfiguration
{
private static readonly object VassalConfigurationLock = new object();
private uint _servicesTimeout = 60000;
 
private ENIGMA _enigma = new ENIGMA
{
@@ -55,7 +57,6 @@
private List<Filter> _outputFilters = new List<Filter>();
private string _password = string.Empty;
private uint _regionRestartDelay = 120;
private uint _servicesTimeout = 60000;
private uint _teleportTimeout = 30000;
private string _vigenereSecret = string.Empty;
 
@@ -243,9 +244,9 @@
{
lock (VassalConfigurationLock)
{
using (var writer = new StreamWriter(file, false, Encoding.UTF8))
using (StreamWriter writer = new StreamWriter(file, false, Encoding.UTF8))
{
var serializer = new XmlSerializer(typeof(VassalConfiguration));
XmlSerializer serializer = new XmlSerializer(typeof (VassalConfiguration));
serializer.Serialize(writer, configuration);
//writer.Flush();
}
@@ -256,10 +257,10 @@
{
lock (VassalConfigurationLock)
{
using (var stream = new StreamReader(file, Encoding.UTF8))
using (StreamReader stream = new StreamReader(file, Encoding.UTF8))
{
var serializer =
new XmlSerializer(typeof(VassalConfiguration));
XmlSerializer serializer =
new XmlSerializer(typeof (VassalConfiguration));
configuration = (VassalConfiguration) serializer.Deserialize(stream);
}
}
/Vassal/Vassal/SettingsForm.cs
@@ -7,6 +7,7 @@
using System;
using System.Drawing;
using System.Linq;
using System.Net;
using System.Net.Http.Headers;
using System.Net.Sockets;
using System.Reflection;
@@ -14,7 +15,6 @@
using System.Windows.Forms;
using OpenMetaverse;
using wasSharp;
using wasSharp.Web;
 
namespace Vassal
{
@@ -89,8 +89,7 @@
mediaType = @"text/plain";
break;
}
Vassal.HTTPClient = new wasHTTPClient(new ProductInfoHeaderValue(@"Vassal", Vassal.VASSAL_VERSION),
mediaType, 60000);
Vassal.HTTPClient = new Web.wasHTTPClient(new ProductInfoHeaderValue(@"Vassal", Vassal.VASSAL_VERSION), mediaType, 60000);
};
 
private readonly Action SetUserConfiguration = () =>
@@ -141,7 +140,7 @@
break;
}
// Create HTTP Client
Vassal.HTTPClient = new wasHTTPClient(new ProductInfoHeaderValue(@"Vassal",
Vassal.HTTPClient = new Web.wasHTTPClient(new ProductInfoHeaderValue(@"Vassal",
Vassal.VASSAL_VERSION), mediaType, 60000);
};
 
/Vassal/Vassal/Vassal.csproj
@@ -121,15 +121,15 @@
<DesignTime>True</DesignTime>
</Compile>
<None Include="..\..\libopenmetaverse-overrides\libopenjpeg-dotnet-2-1.5.0-dotnet-1-arm.so">
<Link>libs\libopenjpeg-dotnet-2-1.5.0-dotnet-1-arm.so</Link>
<Link>libopenjpeg-dotnet-2-1.5.0-dotnet-1-arm.so</Link>
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Include="..\..\libopenmetaverse-overrides\libopenjpeg-dotnet-2-1.5.0-dotnet-1-freebsd.so">
<Link>libs\libopenjpeg-dotnet-2-1.5.0-dotnet-1-freebsd.so</Link>
<Link>libopenjpeg-dotnet-2-1.5.0-dotnet-1-freebsd.so</Link>
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Include="..\..\libopenmetaverse-overrides\libopenjpeg-dotnet-2-1.5.0-dotnet-1-x86_64-freebsd.so">
<Link>libs\libopenjpeg-dotnet-2-1.5.0-dotnet-1-x86_64-freebsd.so</Link>
<Link>libopenjpeg-dotnet-2-1.5.0-dotnet-1-x86_64-freebsd.so</Link>
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Include="Properties\Settings.settings">
@@ -165,8 +165,10 @@
<EmbeddedResource Include="img\online.png" />
<Content Include="Vassal.ico" />
</ItemGroup>
<ItemGroup />
<ItemGroup>
<Folder Include="libs\" />
</ItemGroup>
<ItemGroup>
<BootstrapperPackage Include=".NETFramework,Version=v4.5">
<Visible>False</Visible>
<ProductName>Microsoft .NET Framework 4.5 %28x86 and x64%29</ProductName>
/Vassal/Vassal/VassalForm.cs
@@ -11,6 +11,7 @@
using System.Drawing.Imaging;
using System.IO;
using System.Linq;
using System.Net;
using System.Net.Http.Headers;
using System.Net.Sockets;
using System.Reflection;
@@ -20,8 +21,6 @@
using System.Windows.Forms;
using OpenMetaverse;
using wasSharp;
using wasSharp.Web;
using wasSharp.Web.Utilities;
using Parallel = System.Threading.Tasks.Parallel;
using Timer = System.Timers.Timer;
 
@@ -41,7 +40,7 @@
public static Vassal vassalForm;
public static readonly object ClientInstanceTeleportLock = new object();
public static readonly object RegionsStateCheckLock = new object();
public static wasHTTPClient HTTPClient;
public static Web.wasHTTPClient HTTPClient;
 
/// <summary>
/// Corrade version.
@@ -60,10 +59,10 @@
switch (filter)
{
case Filter.RFC1738:
o = Extensions.URLUnescapeDataString(o);
o = Web.URLUnescapeDataString(o);
break;
case Filter.RFC3986:
o = Extensions.URIUnescapeDataString(o);
o = Web.URIUnescapeDataString(o);
break;
case Filter.ENIGMA:
o = Cryptography.ENIGMA(o, vassalConfiguration.ENIGMA.rotors.ToArray(),
@@ -96,10 +95,10 @@
switch (filter)
{
case Filter.RFC1738:
o = Extensions.URLEscapeDataString(o);
o = Web.URLEscapeDataString(o);
break;
case Filter.RFC3986:
o = Extensions.URIEscapeDataString(o);
o = Web.URIEscapeDataString(o);
break;
case Filter.ENIGMA:
o = Cryptography.ENIGMA(o, vassalConfiguration.ENIGMA.rotors.ToArray(),
@@ -436,7 +435,7 @@
break;
}
// Create HTTP Client
HTTPClient = new wasHTTPClient(new ProductInfoHeaderValue(@"Vassal",
HTTPClient = new Web.wasHTTPClient(new ProductInfoHeaderValue(@"Vassal",
VASSAL_VERSION), mediaType, vassalConfiguration.ServicesTimeout);
}