Update PreferencesHelper.cs

Now properly parses int, long, double and float values. Funny, this was working before, don't remember ever having to do a TryParse() on any of those...