コード例 #1
0
        public OverlayEndCreditsItemViewModel(OverlayEndCreditsItemModel item)
            : this()
        {
            this.speed            = item.Speed;
            this.BackgroundColor  = ColorSchemes.GetColorName(item.BackgroundColor);
            this.SectionTextFont  = item.SectionTextFont;
            this.SectionTextColor = ColorSchemes.GetColorName(item.SectionTextColor);
            this.sectionTextSize  = item.SectionTextSize;
            this.ItemTextFont     = item.ItemTextFont;
            this.ItemTextColor    = ColorSchemes.GetColorName(item.ItemTextColor);
            this.itemTextSize     = item.ItemTextSize;

            this.HTML = item.TitleTemplate;

            this.SectionItems.AddRange(item.SectionTemplates.Select(kvp => new OverlayEndCreditsSectionItemViewModel(this, kvp.Value)));
        }
コード例 #2
0
        public OverlayEndCreditsItemControl(OverlayEndCreditsItemModel item)
        {
            InitializeComponent();

            this.viewModel = new OverlayEndCreditsItemViewModel(item);
        }