public EditMaterial(Material material, IUpdate caller) { InitializeComponent(); book = new AddNewBooks2(this) { Anchor = AnchorStyles.Top | AnchorStyles.Bottom }; lecture = new AddNewLectures2(this) { Anchor = AnchorStyles.Top | AnchorStyles.Bottom }; section = new AddNewSections2(this) { Anchor = AnchorStyles.Top | AnchorStyles.Bottom }; update = caller; this.material = material; textBox1.Text = material.Name; avaliblelectures = new List <Lecture>(); avaliblebooks = new List <Book>(); avaliblesections = new List <Section>(); selectedlectures = material.Lectures; selectedsections = material.Sections; selectedbooks = material.Books; Initialize(); }
private void LinkLabel2_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) { lecture = new AddNewLectures2(this) { Anchor = AnchorStyles.Top | AnchorStyles.Bottom }; lecture.Size = this.Size; this.Controls.Add(lecture); lecture.BringToFront(); }
public AddNewMaterial2(IExitAddNewMaterial caller) { InitializeComponent(); book = new AddNewBooks2(this) { Anchor = AnchorStyles.Top | AnchorStyles.Bottom }; lecture = new AddNewLectures2(this) { Anchor = AnchorStyles.Top | AnchorStyles.Bottom }; section = new AddNewSections2(this) { Anchor = AnchorStyles.Top | AnchorStyles.Bottom }; exit = caller; avaliblelectures = new List <Lecture>(); avaliblebooks = new List <Book>(); avaliblesections = new List <Section>(); selectedlectures = new List <Lecture>(); selectedsections = new List <Section>(); selectedbooks = new List <Book>(); Initialize(); }