Example #1
0
		public Show AddShow()
		{
			Show show = new Show();
			show.Name = "New Show";
			Shows.Add(show);
			return show;
		}
Example #2
0
 protected void PopulateShowList(Show selectedShow)
 {
     listViewShows.Items.Clear();
     foreach (Show show in Data.Shows)
     {
         ListViewItem lvItem = new ListViewItem(show.Name);
         lvItem.Tag = show;
         listViewShows.Items.Add(lvItem);
         if (show == selectedShow)
         {
             lvItem.Selected = true;
         }
     }
 }
Example #3
0
        public ShowEditorForm(Show show)
        {
            InitializeComponent();

            buttonAddItem.Image = Tools.GetIcon(Resources.add, 16);
            buttonAddItem.Text = "";
            buttonDeleteItem.Image = Tools.GetIcon(Resources.delete, 16);
            buttonDeleteItem.Text = "";
            buttonMoveItemUp.Image = Tools.GetIcon(Resources.arrow_up, 16);
            buttonMoveItemUp.Text = "";
            buttonMoveItemDown.Image = Tools.GetIcon(Resources.arrow_down, 16);
            buttonMoveItemDown.Text = "";
            buttonHelp.Image = Tools.GetIcon(Resources.help, 16);

            ShowData = show;
        }
Example #4
0
		public ShowEditorForm(Show show)
		{
			InitializeComponent();

			ForeColor = ThemeColorTable.ForeColor;
			BackColor = ThemeColorTable.BackgroundColor;
			
			buttonAddItem.Image = Tools.GetIcon(Resources.add, 24);
			buttonAddItem.Text = "";
			buttonDeleteItem.Image = Tools.GetIcon(Resources.delete, 24);
			buttonDeleteItem.Text = "";
			buttonHelp.Image = Tools.GetIcon(Resources.help, 24);

			ThemeUpdateControls.UpdateControls(this);

			tabControlShowItems.AutoSize = true;
			tabControlShowItems.SizeMode = TabSizeMode.Fixed;
			
			var tabWidth = 0;
			var tabHeight = 0;
			foreach (Control tab in tabControlShowItems.TabPages)
			{
				tab.BackColor = ThemeColorTable.ComboBoxBackColor;
				tab.ForeColor = ThemeColorTable.ForeColor;
				Graphics g = tab.CreateGraphics();
				SizeF s = g.MeasureString(tab.Text, tab.Font);
				tabWidth = Math.Max(tabWidth, (int)s.Width+10);
				tabHeight = Math.Max(tabHeight, (int)s.Height);
			}

			tabWidth = Math.Min(tabControlShowItems.Width - 10/tabControlShowItems.TabPages.Count, tabWidth);

			tabControlShowItems.ItemSize = new Size(tabWidth, tabHeight);

			tabControlShowItems.SelectedTabColor = ThemeColorTable.ComboBoxBackColor;
			tabControlShowItems.TabColor = ThemeColorTable.ComboBoxHighlightColor;

			


			ShowData = show;
		}
Example #5
0
        public ShowEditorForm(Show show)
        {
            InitializeComponent();

            ForeColor = ThemeColorTable.ForeColor;
            BackColor = ThemeColorTable.BackgroundColor;
            ThemeUpdateControls.UpdateControls(this);
            buttonAddItem.Image = Tools.GetIcon(Resources.add, 16);
            buttonAddItem.Text = "";
            buttonDeleteItem.Image = Tools.GetIcon(Resources.delete, 16);
            buttonDeleteItem.Text = "";
            buttonHelp.Image = Tools.GetIcon(Resources.help, 16);
            foreach (Control tab in tabControlShowItems.TabPages)
            {
                tab.BackColor = ThemeColorTable.ComboBoxBackColor;
                tab.ForeColor = ThemeColorTable.ForeColor;
            }
            tabControlShowItems.SelectedTabColor = ThemeColorTable.ComboBoxBackColor;
            tabControlShowItems.TabColor = ThemeColorTable.ComboBoxHighlightColor;

            ShowData = show;
        }
Example #6
0
 public ShowEditorForm(Show show)
 {
     InitializeComponent();
     ShowData = show;
 }
Example #7
0
        private void buttonAdd_Click(object sender, EventArgs e)
        {
            Show show = Data.AddShow();

            PopulateShowList(show);
        }