diff --git a/Enigma/Enigma.csproj b/Enigma/Enigma.csproj
index c87a889..4959c33 100644
--- a/Enigma/Enigma.csproj
+++ b/Enigma/Enigma.csproj
@@ -62,16 +62,24 @@
-
+
Form
-
- DebugForm.cs
+
+ DebugStationView.cs
-
- DebugForm.cs
+
+ Form
+
+
+ HostStationView.cs
+
+
+
+
+ DebugStationView.cs
ResXFileCodeGenerator
@@ -82,6 +90,9 @@
True
Resources.resx
+
+ HostStationView.cs
+
SettingsSingleFileGenerator
@@ -102,6 +113,7 @@
EnigmaX
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ text/microsoft-resx
+
+
+ 2.0
+
+
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
\ No newline at end of file
diff --git a/EnigmaX/Classes/Station.cs b/EnigmaX/Classes/Station.cs
index 162ac34..59bec25 100644
--- a/EnigmaX/Classes/Station.cs
+++ b/EnigmaX/Classes/Station.cs
@@ -3,20 +3,23 @@
using System.Linq;
using System.Text;
using System.Threading.Tasks;
+using System.Windows.Forms;
namespace EnigmaX.Classes
{
public enum StationTypeDef { chef, waiter, admin, host };
- public class Station
+ public abstract class Station
{
- private string stationId = "";
- private StationTypeDef stationType;
- public Intercom interCom;
+ private string _stationId = "";
+ private StationTypeDef _stationType;
private bool _registered;
+ public Form view;
+ public Intercom interCom;
+
public string StationID {
get {
- return stationId;
+ return _stationId;
}
}
@@ -30,28 +33,35 @@ public StationTypeDef StationType
{
get
{
- return stationType;
+ return _stationType;
}
}
public Station(StationTypeDef type, string stationid) {
- stationType = type;
+ _stationType = type;
if (stationid.Contains("%") || stationid.Contains("-") || stationid.Contains("|"))
{
throw new Exception("StationID cannot contain %, -, or | special characters");
}
else
{
- stationId = stationid;
+ _stationId = stationid;
}
}
public bool registerStation() {
- interCom = new Intercom(stationId, stationType);
+ interCom = new Intercom(_stationId, _stationType);
_registered = interCom.register();
return _registered;
}
+ public virtual void showView() {
+ if (view != null) {
+ view.Show();
+ view.WindowState = FormWindowState.Maximized;
+ }
+ }
+
}