Skip to content

Commit

Permalink
Added the "en-GB" culture so that people with comma as the decimal se…
Browse files Browse the repository at this point in the history
…parator can run the program. Using InvariantCulture would be better but doesn't sit well with the AttributeValueOrThrow ext. method.
  • Loading branch information
K3UL committed Nov 1, 2016
1 parent cc32164 commit 70aa5d0
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions F1InXAML/MainViewModel.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
using System;
using System.ComponentModel;
using System.Globalization;
using System.Linq;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Threading;
using System.Windows.Input;
using System.Windows.Markup;

Expand All @@ -15,6 +17,9 @@ public class MainViewModel : INotifyPropertyChanged, ISlideNavigationSubject

public MainViewModel()
{
CultureInfo ci = new CultureInfo("en-GB");
Thread.CurrentThread.CurrentCulture = ci;

CommandManager.RegisterClassCommandBinding(typeof(MainWindow), new CommandBinding(NavigationCommands.ShowRaceCommand, ShowRaceExecuted));
CommandManager.RegisterClassCommandBinding(typeof(MainWindow), new CommandBinding(NavigationCommands.ShowSeasonCommand, ShowSeasonExecuted));
CommandManager.RegisterClassCommandBinding(typeof(MainWindow), new CommandBinding(NavigationCommands.GoBackCommand, GoBackExecuted));
Expand Down

0 comments on commit 70aa5d0

Please sign in to comment.