예제 #1
0
        internal static CultureInfo GetUserDefaultCulture()
        {
            CultureInfo cultureInfo = null;
            string      localeName;

            if (CultureData.GetDefaultLocaleName(out localeName))
            {
                cultureInfo             = GetCultureByName(localeName, true);
                cultureInfo._isReadOnly = true;
            }
            else
            {
                cultureInfo = CultureInfo.InvariantCulture;
            }

            return(cultureInfo);
        }
예제 #2
0
        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);
        }