diff --git a/.gitignore b/.gitignore
index 6c9e3630..fd34b967 100644
--- a/.gitignore
+++ b/.gitignore
@@ -41,6 +41,7 @@ build/m4/shave/shave-libtool
SparkleLib/Defines.cs
SparkleLib/windows/Defines.cs
SparkleLib/windows/GlobalAssemblyInfo.cs
+SparkleShare/Windows/Strings.cs
SparkleShare/sparkleshare
po/sparkleshare.pot
SparkleShare/Nautilus/sparkleshare-nautilus-extension.py
diff --git a/SparkleShare/Windows/Program.cs b/SparkleShare/Windows/Program.cs
index 50e42c1c..b254ea4f 100644
--- a/SparkleShare/Windows/Program.cs
+++ b/SparkleShare/Windows/Program.cs
@@ -18,6 +18,7 @@
using System;
using System.Collections.Generic;
using System.Diagnostics;
+using System.Globalization;
using System.IO;
using System.Runtime.InteropServices;
using System.Text;
@@ -44,7 +45,7 @@ namespace SparkleShare {
#if __MonoCS__
return Catalog.GetString (s);
#else
- return s;
+ return Strings.T(s);
#endif
}
@@ -53,6 +54,9 @@ namespace SparkleShare {
#endif
public static void Main (string [] args)
{
+ //var culture = CultureInfo.GetCultureInfo ("en"); // FIXME: test only
+ //System.Threading.Thread.CurrentThread.CurrentUICulture = culture;
+
// Parse the command line options
bool show_help = false;
OptionSet option_set = new OptionSet () {
diff --git a/SparkleShare/Windows/SparkleShare.csproj b/SparkleShare/Windows/SparkleShare.csproj
index 04d1290a..a48328d9 100644
--- a/SparkleShare/Windows/SparkleShare.csproj
+++ b/SparkleShare/Windows/SparkleShare.csproj
@@ -55,7 +55,12 @@
+
+ False
+ ..\..\tools\gettext-cs-utils\Gettext.CsUtils\Core\Gettext.Cs\bin\Release\Gettext.Cs.dll
+
+
3.5
@@ -137,6 +142,11 @@
Component
+
+ True
+ True
+ Strings.tt
+
@@ -271,5 +281,125 @@
plugins\own-server.xml
Always
+
+ po\ar.po
+ Always
+
+
+ po\bg.po
+ Always
+
+
+ po\ca.po
+ Always
+
+
+ po\cs_CZ.po
+ Always
+
+
+ po\da.po
+ Always
+
+
+ po\de.po
+ Always
+
+
+ po\el.po
+ Always
+
+
+ po\eo.po
+ Always
+
+
+ po\es.po
+ Always
+
+
+ po\fi.po
+ Always
+
+
+ po\fr.po
+ Always
+
+
+ po\he.po
+ Always
+
+
+ po\hu.po
+ Always
+
+
+ po\it.po
+ Always
+
+
+ po\ja.po
+ Always
+
+
+ po\nl.po
+ Always
+
+
+ po\nn_NO.po
+ Always
+
+
+ po\no_NO.po
+ Always
+
+
+ po\pl.po
+ Always
+
+
+ po\pt_BR.po
+ Always
+
+
+ po\ru.po
+ Always
+
+
+ po\sk.po
+ Always
+
+
+ po\sl.po
+ Always
+
+
+ po\sr_RS.po
+ Always
+
+
+ po\sv.po
+ Always
+
+
+ po\te.po
+ Always
+
+
+ po\uk.po
+ Always
+
+
+ po\zh_CN.po
+ Always
+
+
+ po\zh_TW.po
+ Always
+
+
+ TextTemplatingFileGenerator
+ Strings.cs
+
\ No newline at end of file
diff --git a/SparkleShare/Windows/Strings.tt b/SparkleShare/Windows/Strings.tt
new file mode 100644
index 00000000..15a29926
--- /dev/null
+++ b/SparkleShare/Windows/Strings.tt
@@ -0,0 +1,10 @@
+<#@ assembly name="System.Configuration" #>
+
+<#
+ this.ClassName = "Strings";
+ this.ResourceName = "Strings";
+ this.NamespaceName = "SparkleShare";
+ this.DefaultResourceDir = "po";
+ this.DefaultFileFormat = "{{culture}}.po";
+#>
+<#@ include file="..\..\tools\gettext-cs-utils\Gettext.CsUtils\Core\Gettext.Cs\Templates\Strings.tt" #>
diff --git a/SparkleShare/Windows/build.cmd b/SparkleShare/Windows/build.cmd
index 282fc313..2f4ab8ea 100644
--- a/SparkleShare/Windows/build.cmd
+++ b/SparkleShare/Windows/build.cmd
@@ -7,6 +7,11 @@ set msbuild="%WinDirNet%\v3.5\msbuild.exe"
if not exist %msbuild% set msbuild="%WinDirNet%\v4.0.30319\msbuild.exe"
set wixBinDir=%WIX%\bin
+
+
+%msbuild% /t:Rebuild /p:Configuration=Release /p:Platform="AnyCPU" %~dp0..\..\tools\gettext-cs-utils\Gettext.CsUtils\Core\Gettext.Cs\Gettext.Cs.csproj
+
+
%msbuild% /t:Rebuild /p:Configuration=Release /p:Platform="Any CPU" %~dp0\SparkleShare.sln
if "%1"=="installer" (