Exemple #1
0
        private IconImage GetIconImageImpl(int size)
        {
            if (MultiIcon == null || !MultiIcon.Any())
            {
                return(null);
            }
            var icons = MultiIcon.First()
                        .Where(image => image.Size.Width == size)
                        .OrderByDescending(image => image.ColorsInPalette);

            return(icons.FirstOrDefault());
        }
Exemple #2
0
        public IconImage GetProgramIconImage(int size)
        {
            if (_multiIcon == null || !_multiIcon.Any())
            {
                return(null);
            }
            var sizeObj = new Size(size, size);

            return(_multiIcon.First()
                   .Where(img => img.Size.Equals(sizeObj))
                   .OrderByDescending(img => img.ColorsInPalette)
                   .FirstOrDefault());
        }