mirror of
https://github.com/sourcegit-scm/sourcegit.git
synced 2024-12-23 20:47:25 -08:00
Resx Folder Location
This commit is contained in:
parent
14550655f3
commit
aa4c7be813
6 changed files with 13 additions and 9 deletions
|
@ -93,11 +93,11 @@ namespace SourceGit
|
|||
|
||||
Thread.CurrentThread.CurrentUICulture = CultureInfo.GetCultureInfo(localeKey);
|
||||
Thread.CurrentThread.CurrentCulture = Thread.CurrentThread.CurrentUICulture ;
|
||||
Assets.Resources.Culture = Thread.CurrentThread.CurrentUICulture;
|
||||
SourceGit.Resources.Locales.Culture = Thread.CurrentThread.CurrentUICulture;
|
||||
|
||||
var locale = new ResourceDictionary();
|
||||
var res = new Assets.Resources();
|
||||
var props = typeof(Assets.Resources).GetProperties()
|
||||
var res = new Resources.Locales();
|
||||
var props = typeof(Resources.Locales).GetProperties()
|
||||
.Where(m=> m.PropertyType == typeof(string))
|
||||
.ToDictionary(k=> k.Name.Replace("_", "."), v=> v.GetValue(res));
|
||||
foreach (var prop in props)
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace SourceGit.Assets {
|
||||
namespace SourceGit.Resources {
|
||||
using System;
|
||||
|
||||
|
||||
|
@ -21,14 +21,14 @@ namespace SourceGit.Assets {
|
|||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
public class Resources {
|
||||
public class Locales {
|
||||
|
||||
private static global::System.Resources.ResourceManager resourceMan;
|
||||
|
||||
private static global::System.Globalization.CultureInfo resourceCulture;
|
||||
|
||||
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
|
||||
public Resources() {
|
||||
public Locales() {
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -38,7 +38,7 @@ namespace SourceGit.Assets {
|
|||
public static global::System.Resources.ResourceManager ResourceManager {
|
||||
get {
|
||||
if (object.ReferenceEquals(resourceMan, null)) {
|
||||
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("SourceGit.Assets.Resources", typeof(Resources).Assembly);
|
||||
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("SourceGit.Resources.Locales", typeof(Locales).Assembly);
|
||||
resourceMan = temp;
|
||||
}
|
||||
return resourceMan;
|
|
@ -48,9 +48,13 @@
|
|||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<EmbeddedResource Update="Assets\Resources.*.resx">
|
||||
<EmbeddedResource Update="Resources\Locales.*.resx">
|
||||
<Generator>ResXFileCodeGenerator</Generator>
|
||||
<DependentUpon>Resources.resx</DependentUpon>
|
||||
<DependentUpon>Locales.resx</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Update="Resources\Locales.*.resx">
|
||||
<Generator>ResXFileCodeGenerator</Generator>
|
||||
<DependentUpon>Locales.resx</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
</ItemGroup>
|
||||
|
||||
|
|
Loading…
Reference in a new issue