mirror of
https://github.com/ppy/osu.git
synced 2024-12-13 03:42:57 +08:00
Change tournament date text box parsing to use invariant culture info
This commit is contained in:
parent
c5ff708c6f
commit
c38c8e933a
@ -2,6 +2,7 @@
|
||||
// See the LICENCE file in the repository root for full licence text.
|
||||
|
||||
using System;
|
||||
using System.Globalization;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Game.Graphics.UserInterface;
|
||||
using osu.Game.Overlays.Settings;
|
||||
@ -23,13 +24,13 @@ namespace osu.Game.Tournament.Components
|
||||
base.Current = new Bindable<string>(string.Empty);
|
||||
|
||||
current.BindValueChanged(dto =>
|
||||
base.Current.Value = dto.NewValue.ToUniversalTime().ToString("yyyy-MM-ddTHH:mm:ssZ"), true);
|
||||
base.Current.Value = dto.NewValue.ToUniversalTime().ToString("yyyy-MM-ddTHH:mm:ssZ", DateTimeFormatInfo.InvariantInfo), true);
|
||||
|
||||
((OsuTextBox)Control).OnCommit += (sender, _) =>
|
||||
{
|
||||
try
|
||||
{
|
||||
current.Value = DateTimeOffset.Parse(sender.Text);
|
||||
current.Value = DateTimeOffset.Parse(sender.Text, DateTimeFormatInfo.InvariantInfo);
|
||||
}
|
||||
catch
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user