Esempio n. 1
0
        /// <summary>
        /// Function to get the current user's Theme preference
        /// </summary>
        void GetThemeSetting()
        {
            string theme = Settings.GetSetting(Settings.AppPrefrences.AppTheme);

            var appTheme = EnumsHelper.ConvertToEnum <Settings.Theme>(theme);

            switch (appTheme)
            {
            case Settings.Theme.LightTheme:
                IsLightTheme = true;
                break;

            case Settings.Theme.DarkTheme:
                IsDarkTheme = true;
                break;

            case Settings.Theme.SystemPreferred:
                IsSystemPreferredTheme = true;
                break;

            default:
                IsSystemPreferredTheme = true;
                break;
            }
        }