Skip to content

Commit

Permalink
Fixed invalid localization for colors (comma vs dot)
Browse files Browse the repository at this point in the history
  • Loading branch information
X39 committed Mar 14, 2020
1 parent b17217f commit 1666c48
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions Arma.Studio.UiEditor/UI/UiEditorDataContext.cs
Original file line number Diff line number Diff line change
Expand Up @@ -668,13 +668,13 @@ async Task WriteOutConfig(Type t, object obj)
{
await stream.WriteAsync("[] = { ");
var color = (System.Windows.Media.Color)value;
await stream.WriteAsync(Convert.ToString(color.R / 255.0));
await stream.WriteAsync(Convert.ToString(color.R / 255.0, System.Globalization.CultureInfo.InvariantCulture));
await stream.WriteAsync(", ");
await stream.WriteAsync(Convert.ToString(color.G / 255.0));
await stream.WriteAsync(Convert.ToString(color.G / 255.0, System.Globalization.CultureInfo.InvariantCulture));
await stream.WriteAsync(", ");
await stream.WriteAsync(Convert.ToString(color.B / 255.0));
await stream.WriteAsync(Convert.ToString(color.B / 255.0, System.Globalization.CultureInfo.InvariantCulture));
await stream.WriteAsync(", ");
await stream.WriteAsync(Convert.ToString(color.A / 255.0));
await stream.WriteAsync(Convert.ToString(color.A / 255.0, System.Globalization.CultureInfo.InvariantCulture));
await stream.WriteAsync(" }");
}
else if (propertyInfo.PropertyType.IsEnum)
Expand All @@ -690,7 +690,7 @@ async Task WriteOutConfig(Type t, object obj)
else
{
await stream.WriteAsync(" = ");
await stream.WriteAsync(Convert.ToString(value));
await stream.WriteAsync(Convert.ToString(value, System.Globalization.CultureInfo.InvariantCulture));
}
await stream.WriteLineAsync(";");
}
Expand Down

0 comments on commit 1666c48

Please sign in to comment.