This commit is contained in:
Michiel.VanDorpe
2019-08-04 20:44:25 +02:00
parent b3a4a7441a
commit 41a10e710c
4 changed files with 27 additions and 5 deletions

View File

@@ -104,6 +104,7 @@
this.label3.Size = new System.Drawing.Size(35, 13); this.label3.Size = new System.Drawing.Size(35, 13);
this.label3.TabIndex = 7; this.label3.TabIndex = 7;
this.label3.Text = "label3"; this.label3.Text = "label3";
this.label3.Click += new System.EventHandler(this.label3_Click);
// //
// label4 // label4
// //

View File

@@ -1,4 +1,5 @@
using Logic; using Globals.classes;
using Logic;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.ComponentModel; using System.ComponentModel;
@@ -14,10 +15,12 @@ namespace GUI_Gokkantoor
public partial class Gokspel : Form public partial class Gokspel : Form
{ {
public LogicLayer l; public LogicLayer l;
public Gokspel(Logic.LogicLayer l) public Person p;
public Gokspel(Logic.LogicLayer l, Person p)
{ {
l = new LogicLayer(); this.l = l;
InitializeComponent(); InitializeComponent();
this.p = p;
} }
private void label2_Click(object sender, EventArgs e) private void label2_Click(object sender, EventArgs e)
@@ -49,5 +52,10 @@ namespace GUI_Gokkantoor
a.FormClosed += adminClosed; a.FormClosed += adminClosed;
a.Show(); a.Show();
} }
private void label3_Click(object sender, EventArgs e)
{
}
} }
} }

View File

@@ -39,6 +39,7 @@
this.listBox1.Name = "listBox1"; this.listBox1.Name = "listBox1";
this.listBox1.Size = new System.Drawing.Size(186, 186); this.listBox1.Size = new System.Drawing.Size(186, 186);
this.listBox1.TabIndex = 0; this.listBox1.TabIndex = 0;
this.listBox1.SelectedIndexChanged += new System.EventHandler(this.listBox1_SelectedIndexChanged);
// //
// button1 // button1
// //

View File

@@ -1,4 +1,5 @@
using Logic; using Globals.classes;
using Logic;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.ComponentModel; using System.ComponentModel;
@@ -18,11 +19,17 @@ namespace GUI_Gokkantoor
{ {
l = new LogicLayer(); l = new LogicLayer();
InitializeComponent(); InitializeComponent();
listBox1.DataSource = l.persons;
} }
private void button1_Click(object sender, EventArgs e) private void button1_Click(object sender, EventArgs e)
{ {
Gokspel a = new Gokspel(l); Person p = (Person)listBox1.SelectedItem;
Gokspel a = new Gokspel(l,p);
this.Hide(); this.Hide();
a.FormClosed += adminClosed; a.FormClosed += adminClosed;
a.Show(); a.Show();
@@ -31,5 +38,10 @@ namespace GUI_Gokkantoor
{ {
this.Show(); this.Show();
} }
private void listBox1_SelectedIndexChanged(object sender, EventArgs e)
{
}
} }
} }