| 123456789101112131415161718192021222324252627282930313233 |
- // Licensed to the .NET Foundation under one or more agreements.
- // The .NET Foundation licenses this file to you under the MIT license.
- // See the LICENSE file in the project root for more information.
- namespace System.Globalization
- {
- public partial class CultureInfo : IFormatProvider
- {
- internal static CultureInfo GetUserDefaultCulture()
- {
- if (GlobalizationMode.Invariant)
- return CultureInfo.InvariantCulture;
- CultureInfo cultureInfo = null;
- string localeName;
- if (CultureData.GetDefaultLocaleName(out localeName))
- {
- cultureInfo = GetCultureByName(localeName);
- }
- else
- {
- cultureInfo = CultureInfo.InvariantCulture;
- }
- return cultureInfo;
- }
- private static CultureInfo GetUserDefaultUICulture()
- {
- return InitializeUserDefaultCulture();
- }
- }
- }
|