diff --git a/BizHawk.MultiClient/BizHawk.MultiClient.csproj b/BizHawk.MultiClient/BizHawk.MultiClient.csproj
index 4eea55c768..3e548286ff 100644
--- a/BizHawk.MultiClient/BizHawk.MultiClient.csproj
+++ b/BizHawk.MultiClient/BizHawk.MultiClient.csproj
@@ -166,6 +166,9 @@
ControllerConfig.cs
+
+ Component
+
Component
diff --git a/BizHawk.MultiClient/config/ControllerConfig/GamepadConfigPanel.cs b/BizHawk.MultiClient/config/ControllerConfig/GamepadConfigPanel.cs
new file mode 100644
index 0000000000..b85d097289
--- /dev/null
+++ b/BizHawk.MultiClient/config/ControllerConfig/GamepadConfigPanel.cs
@@ -0,0 +1,56 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Windows.Forms;
+using System.Drawing;
+
+namespace BizHawk.MultiClient
+{
+ class GamepadConfigPanel : Panel
+ {
+ public static List buttons = new List();
+ public int ControllerNumber = 1;
+ public bool Autofire = false;
+
+ public int InputMarginLeft = 0;
+ public int LabelPadding = 20;
+
+ public int MarginTop = 0;
+ public int Spacing = 30;
+ public int InputSize = 200;
+
+ public GamepadConfigPanel()
+ {
+ Size = new Size(174, 74);
+ this.BorderStyle = BorderStyle.None;
+ Startup();
+ }
+
+ public void Startup()
+ {
+ for (int i = 0; i < buttons.Count; i++)
+ {
+ int pos = i + 1;
+
+ InputWidget iw = new InputWidget();
+ iw.Location = new Point(InputMarginLeft, MarginTop + (pos * Spacing));
+ iw.Size = new Size(InputSize, 23);
+ Controls.Add(iw);
+
+ Label l = new Label();
+ l.Location = new Point(InputMarginLeft + InputSize + LabelPadding, MarginTop + (pos * Spacing) + 3);
+ l.Text = buttons[i];
+ Controls.Add(l);
+ }
+ }
+
+ public virtual void Save()
+ {
+ for (int button = 0; button < 8; button++)
+ {
+
+ }
+ }
+ }
+}
diff --git a/BizHawk.MultiClient/config/ControllerConfig/NESGamePad.cs b/BizHawk.MultiClient/config/ControllerConfig/NESGamePad.cs
index a43d6cc4d2..a986189706 100644
--- a/BizHawk.MultiClient/config/ControllerConfig/NESGamePad.cs
+++ b/BizHawk.MultiClient/config/ControllerConfig/NESGamePad.cs
@@ -7,104 +7,19 @@ using System.Drawing;
namespace BizHawk.MultiClient
{
- class NESGamePad : Panel
+ class NESGamePad : GamepadConfigPanel
{
- public InputWidget UpBox = new InputWidget();
- public InputWidget DownBox = new InputWidget();
- public InputWidget LeftBox = new InputWidget();
- public InputWidget RightBox = new InputWidget();
- public InputWidget ABox = new InputWidget();
- public InputWidget BBox = new InputWidget();
- public InputWidget SelectBox = new InputWidget();
- public InputWidget StartBox = new InputWidget();
-
- public Label UpLabel = new Label();
- public Label DownLabel = new Label();
- public Label LeftLabel = new Label();
- public Label RightLabel = new Label();
- public Label ALabel = new Label();
- public Label BLabel = new Label();
- public Label SelectLabel = new Label();
- public Label StartLabel = new Label();
-
- public int ControllerNumber = 1;
- public bool Autofire = false;
-
public NESGamePad()
{
- this.BorderStyle = BorderStyle.Fixed3D;
- this.Size = new Size(174, 74);
- ControllerNumber = 1;
-
- UpBox.Location = new Point(15, 15);
- UpBox.Size = new Size(200, 23);
-
- DownBox.Location = new Point(15, 45);
- DownBox.Size = new Size(200, 23);
-
- LeftBox.Location = new Point(15, 75);
- LeftBox.Size = new Size(200, 23);
-
- RightBox.Location = new Point(15, 105);
- RightBox.Size = new Size(200, 23);
-
- ABox.Location = new Point(15, 135);
- ABox.Size = new Size(200, 23);
-
- BBox.Location = new Point(15, 165);
- BBox.Size = new Size(200, 23);
-
- SelectBox.Location = new Point(15, 195);
- SelectBox.Size = new Size(200, 23);
-
- StartBox.Location = new Point(15, 225);
- StartBox.Size = new Size(200, 23);
-
- UpLabel.Text = "Up";
- UpLabel.Location = new Point(220, 18);
-
- DownLabel.Text = "Down";
- DownLabel.Location = new Point(220, 48);
-
- LeftLabel.Text = "Left";
- LeftLabel.Location = new Point(220, 78);
-
- RightLabel.Text = "Right";
- RightLabel.Location = new Point(220, 108);
-
- ALabel.Text = "A";
- ALabel.Location = new Point(220, 138);
-
- BLabel.Text = "B";
- BLabel.Location = new Point(220, 168);
-
- SelectLabel.Text = "Select";
- SelectLabel.Location = new Point(220, 198);
-
- StartLabel.Text = "Start";
- StartLabel.Location = new Point(220, 228);
-
- this.Controls.Add(this.UpBox);
- this.Controls.Add(this.DownBox);
- this.Controls.Add(this.LeftBox);
- this.Controls.Add(this.RightBox);
- this.Controls.Add(this.ABox);
- this.Controls.Add(this.BBox);
- this.Controls.Add(this.SelectBox);
- this.Controls.Add(this.StartBox);
-
- this.Controls.Add(this.UpLabel);
- this.Controls.Add(this.DownLabel);
- this.Controls.Add(this.LeftLabel);
- this.Controls.Add(this.RightLabel);
- this.Controls.Add(this.ALabel);
- this.Controls.Add(this.BLabel);
- this.Controls.Add(this.SelectLabel);
- this.Controls.Add(this.StartLabel);
-
- this.BorderStyle = BorderStyle.None;
+ buttons = new List { "Up", "Down", "Left", "Right", "A", "B", "Select", "Start" };
}
+ public override void Save()
+ {
+ for (int button = 0; button < 8; button++)
+ {
+ }
+ }
}
}