Ejemplo n.º 1
0
        public async Task SaveThemes(IEnumerable <Theme> themes)
        {
            await _manager.TruncateData("Themes");

            await _manager.AddListOfData("Themes",
                                         from theme in themes
                                         select new ThemeDb
            {
                Id         = theme.Id,
                Name       = theme.Name,
                Background = GetStringFromColor(theme.Background.Color),
                Foreground = GetStringFromColor(theme.Foreground.Color),
                Hover      = GetStringFromColor(theme.Hover.Color),
                DarkIcons  = theme.DarkIcons
            });
        }