private void ApplyTheme()
        {
            if ((App.Current as App).WhiteTheme)
            {
                var whiteTheme = new WhiteTheme();

                foreach (var key in whiteTheme.Keys)
                {
                    if (Application.Current.Resources.ContainsKey(key))
                    {
                        Application.Current.Resources[key] = whiteTheme[key];
                    }
                }
            }
        }
Beispiel #2
0
        private void ApplyTheme()
        {
            if ((Xamarin.Forms.Application.Current as App).WhiteTheme)
            {
                var whiteTheme = new WhiteTheme();

                foreach (var key in whiteTheme.Keys)
                {
                    if (Xamarin.Forms.Application.Current.Resources.ContainsKey(key))
                    {
                        Xamarin.Forms.Application.Current.Resources[key] = whiteTheme[key];
                    }
                }

                backgroundColor = Color.White;
                //backgroundColor = Color.LightPink;
            }
        }