VirtualPad Schema - add some helper methods for creating directional pad buttons, since those are so common

This commit is contained in:
adelikat 2020-03-21 18:12:22 -05:00
parent 4476cc53af
commit a52c46339e
26 changed files with 171 additions and 863 deletions

View File

@ -52,30 +52,10 @@ namespace BizHawk.Client.EmuHawk
MaxSize = new Size(174, 74),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(23, 15)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(23, 36)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 24)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(44, 24)
},
ButtonSchema.Up($"P{controller} Up", 23, 15),
ButtonSchema.Down($"P{controller} Down", 23, 36),
ButtonSchema.Left($"P{controller} Left", 2, 24),
ButtonSchema.Right($"P{controller} Right", 44, 24),
new ButtonSchema
{
Name = $"P{controller} Button",

View File

@ -61,30 +61,10 @@ namespace BizHawk.Client.EmuHawk
MaxSize = new Size(174, 74),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(23, 15)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(23, 36)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 24)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(44, 24)
},
ButtonSchema.Up($"P{controller} Up", 23, 15),
ButtonSchema.Down($"P{controller} Down", 23, 36),
ButtonSchema.Left($"P{controller} Left", 2, 24),
ButtonSchema.Right($"P{controller} Right", 44, 24),
new ButtonSchema
{
Name = $"P{controller} Trigger",

View File

@ -1,5 +1,4 @@
using System.Collections.Generic;
using System.Drawing;
using System.Drawing;
using System.Windows.Forms;
using BizHawk.Emulation.Common;
@ -37,5 +36,33 @@ namespace BizHawk.Client.EmuHawk
// for Analog Stick controls
public ControllerDefinition.AxisRange? AxisRange { get; set; }
public ControllerDefinition.AxisRange? SecondaryAxisRange { get; set; }
public static ButtonSchema Up(string name, int x, int y) => new ButtonSchema
{
Name = name,
Icon = Properties.Resources.BlueUp,
Location = new Point(x, y)
};
public static ButtonSchema Down(string name, int x, int y) => new ButtonSchema
{
Name = name,
Icon = Properties.Resources.BlueDown,
Location = new Point(x, y)
};
public static ButtonSchema Left(string name, int x, int y) => new ButtonSchema
{
Name = name,
Icon = Properties.Resources.Back,
Location = new Point(x, y)
};
public static ButtonSchema Right(string name, int x, int y) => new ButtonSchema
{
Name = name,
Icon = Properties.Resources.Forward,
Location = new Point(x, y)
};
}
}

View File

@ -26,30 +26,10 @@ namespace BizHawk.Client.EmuHawk
MaxSize = new Size(174, 74),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(23, 15)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(23, 36)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 24)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(44, 24)
},
ButtonSchema.Up($"P{controller} Up", 23, 15),
ButtonSchema.Down($"P{controller} Down", 23, 36),
ButtonSchema.Left($"P{controller} Left", 2, 24),
ButtonSchema.Right($"P{controller} Right", 44, 24),
new ButtonSchema
{
Name = $"P{controller} Button",

View File

@ -45,30 +45,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(128, 200),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(50, 11)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(50, 32)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(29, 22)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(71, 22)
},
ButtonSchema.Up($"P{controller} Up", 50, 11),
ButtonSchema.Down($"P{controller} Down", 50, 32),
ButtonSchema.Left($"P{controller} Left", 29, 22),
ButtonSchema.Right($"P{controller} Right", 71, 22),
new ButtonSchema
{
Name = $"P{controller} L",
@ -196,31 +176,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(195, 260),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(50, 11)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(50, 32)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(29, 22)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(71, 22)
},
ButtonSchema.Up($"P{controller} Up", 50, 11),
ButtonSchema.Down($"P{controller} Down", 50, 32),
ButtonSchema.Left($"P{controller} Left", 29, 22),
ButtonSchema.Right($"P{controller} Right", 71, 22),
new ButtonSchema
{
Name = $"P{controller} Key 1",

View File

@ -23,30 +23,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(174, 79),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 12)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 56)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 34)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 34)
},
ButtonSchema.Up($"P{controller} Up", 14, 12),
ButtonSchema.Down($"P{controller} Down", 14, 56),
ButtonSchema.Left($"P{controller} Left", 2, 34),
ButtonSchema.Right($"P{controller} Right", 24, 34),
new ButtonSchema
{
Name = $"P{controller} B",

View File

@ -78,30 +78,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(194, 90),
Buttons = new[]
{
new ButtonSchema
{
Name = "Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(29, 17)
},
new ButtonSchema
{
Name = "Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(29, 61)
},
new ButtonSchema
{
Name = "Left",
Icon = Properties.Resources.Back,
Location = new Point(17, 39)
},
new ButtonSchema
{
Name = "Right",
Icon = Properties.Resources.Forward,
Location = new Point(39, 39)
},
ButtonSchema.Up("Up", 29, 17),
ButtonSchema.Down("Down", 29, 61),
ButtonSchema.Left("Left", 17, 39),
ButtonSchema.Right("Right", 39, 39),
new ButtonSchema
{
Name = "B",

View File

@ -38,30 +38,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(174, 79),
Buttons = new[]
{
new ButtonSchema
{
Name = "Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 12)
},
new ButtonSchema
{
Name = "Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 56)
},
new ButtonSchema
{
Name = "Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 34)
},
new ButtonSchema
{
Name = "Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 34)
},
ButtonSchema.Up("Up", 14, 12),
ButtonSchema.Down("Down", 14, 56),
ButtonSchema.Left("Left", 2, 34),
ButtonSchema.Right("Right", 24, 34),
new ButtonSchema
{
Name = "B",
@ -115,30 +95,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(174, 79),
Buttons = new[]
{
new ButtonSchema
{
Name = "P1 Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 12)
},
new ButtonSchema
{
Name = "P1 Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 56)
},
new ButtonSchema
{
Name = "P1 Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 34)
},
new ButtonSchema
{
Name = "P1 Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 34)
},
ButtonSchema.Up("P1 Up", 14, 12),
ButtonSchema.Down("P1 Down", 14, 56),
ButtonSchema.Left("P1 Left", 2, 34),
ButtonSchema.Right("P1 Right", 24, 34),
new ButtonSchema
{
Name = "P1 B",

View File

@ -23,30 +23,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(174, 90),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 12)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 56)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 34)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 34)
},
ButtonSchema.Up($"P{controller} Up", 14, 12),
ButtonSchema.Down($"P{controller} Down", 14, 56),
ButtonSchema.Left($"P{controller} Left", 2, 34),
ButtonSchema.Right($"P{controller} Right", 24, 34),
new ButtonSchema
{
Name = $"P{controller} Start",

View File

@ -74,30 +74,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(174, 90),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 12)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 56)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 34)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 34)
},
ButtonSchema.Up($"P{controller} Up", 14, 12),
ButtonSchema.Down($"P{controller} Down", 14, 56),
ButtonSchema.Left($"P{controller} Left", 2, 34),
ButtonSchema.Right($"P{controller} Right", 24, 34),
new ButtonSchema
{
Name = $"P{controller} A",
@ -134,30 +114,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(174, 90),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 12)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 56)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 34)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 34)
},
ButtonSchema.Up($"P{controller} Up", 14, 12),
ButtonSchema.Down($"P{controller} Down", 14, 56),
ButtonSchema.Left($"P{controller} Left", 2, 34),
ButtonSchema.Right($"P{controller} Right", 24, 34),
new ButtonSchema
{
Name = $"P{controller} A",
@ -321,30 +281,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(110, 110),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(47, 10)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(47, 73)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(15, 43)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(80, 43)
},
ButtonSchema.Up($"P{controller} Up", 47, 10),
ButtonSchema.Down($"P{controller} Down", 47, 73),
ButtonSchema.Left($"P{controller} Left", 15, 43),
ButtonSchema.Right($"P{controller} Right", 80, 43),
new ButtonSchema
{
Name = $"P{controller} A",

View File

@ -22,40 +22,18 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(194, 90),
Buttons = new[]
{
new ButtonSchema
{
Name = "Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 12)
},
new ButtonSchema
{
Name = "Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 56)
},
new ButtonSchema
{
Name = "Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 34)
},
new ButtonSchema
{
Name = "Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 34)
},
ButtonSchema.Up("Up", 14, 12),
ButtonSchema.Down("Down", 14, 56),
ButtonSchema.Left("Left", 2, 34),
ButtonSchema.Right($"Right", 24, 34),
new ButtonSchema
{
Name = "B",
DisplayName = "B",
Location = new Point(130, 62)
},
new ButtonSchema
{
Name = "A",
DisplayName = "A",
Location = new Point(154, 62)
},
new ButtonSchema
@ -73,7 +51,6 @@ namespace BizHawk.Client.EmuHawk
new ButtonSchema
{
Name = "Pause",
DisplayName = "Pause",
Location = new Point(100, 37)
}
}

View File

@ -31,30 +31,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(275, 316),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} DPad U",
Icon = Properties.Resources.BlueUp,
Location = new Point(24, 230)
},
new ButtonSchema
{
Name = $"P{controller} DPad D",
Icon = Properties.Resources.BlueDown,
Location = new Point(24, 251)
},
new ButtonSchema
{
Name = $"P{controller} DPad L",
Icon = Properties.Resources.Back,
Location = new Point(3, 242)
},
new ButtonSchema
{
Name = $"P{controller} DPad R",
Icon = Properties.Resources.Forward,
Location = new Point(45, 242)
},
ButtonSchema.Up($"P{controller} DPad U", 24, 230),
ButtonSchema.Down($"P{controller} DPad D", 24, 251),
ButtonSchema.Left($"P{controller} DPad L", 3, 242),
ButtonSchema.Right($"P{controller} DPad R", 45, 242),
new ButtonSchema
{
Name = $"P{controller} L",

View File

@ -39,30 +39,10 @@ namespace BizHawk.Client.EmuHawk.tools.VirtualPads.schema
DefaultSize = new Size(440, 260),
Buttons = new []
{
new ButtonSchema
{
Name = "Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 79)
},
new ButtonSchema
{
Name = "Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 122)
},
new ButtonSchema
{
Name = "Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 100)
},
new ButtonSchema
{
Name = "Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 100)
},
ButtonSchema.Up("Up", 14, 79),
ButtonSchema.Down("Down", 14, 122),
ButtonSchema.Left("Left", 2, 100),
ButtonSchema.Right("Right", 24, 100),
new ButtonSchema
{
Name = "L",
@ -83,7 +63,6 @@ namespace BizHawk.Client.EmuHawk.tools.VirtualPads.schema
Name = "Select",
Location = new Point(341, 201)
},
new ButtonSchema
{
Name = "Y",
@ -102,7 +81,6 @@ namespace BizHawk.Client.EmuHawk.tools.VirtualPads.schema
new ButtonSchema
{
Name = "A",
DisplayName = "A",
Location = new Point(366, 86)
},

View File

@ -240,30 +240,10 @@ namespace BizHawk.Client.EmuHawk
MaxSize = new Size(174, 74),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(23, 15)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(23, 36)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 24)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(44, 24)
},
ButtonSchema.Up($"P{controller} Up", 23, 15),
ButtonSchema.Down($"P{controller} Down", 23, 36),
ButtonSchema.Left($"P{controller} Left", 2, 24),
ButtonSchema.Right($"P{controller} Right", 44, 24),
new ButtonSchema
{
Name = $"P{controller} B",
@ -303,30 +283,10 @@ namespace BizHawk.Client.EmuHawk
MaxSize = new Size(174, 74),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(23, 15)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(23, 36)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 24)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(44, 24)
},
ButtonSchema.Up($"P{controller} Up", 23, 15),
ButtonSchema.Down($"P{controller} Down", 23, 36),
ButtonSchema.Left($"P{controller} Left", 2, 24),
ButtonSchema.Right($"P{controller} Right", 44, 24),
new ButtonSchema
{
Name = $"P{controller} B",

View File

@ -23,30 +23,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(174, 79),
Buttons = new[]
{
new ButtonSchema
{
Name = "Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 12)
},
new ButtonSchema
{
Name = "Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 56)
},
new ButtonSchema
{
Name = "Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 34)
},
new ButtonSchema
{
Name = "Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 34)
},
ButtonSchema.Up("Up", 14, 12),
ButtonSchema.Down("Down", 14, 56),
ButtonSchema.Left("Left", 2, 34),
ButtonSchema.Right("Right", 24, 34),
new ButtonSchema
{
Name = "B",

View File

@ -35,30 +35,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(100, 100),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 12)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 56)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 34)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 34)
},
ButtonSchema.Up($"P{controller} Up", 14, 12),
ButtonSchema.Down($"P{controller} Down", 14, 56),
ButtonSchema.Left($"P{controller} Left", 2, 34),
ButtonSchema.Right($"P{controller} Right", 24, 34),
new ButtonSchema
{
Name = $"P{controller} F",

View File

@ -54,30 +54,10 @@ namespace BizHawk.Client.EmuHawk
DisplayName = $"DualShock Player{controller}",
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(32, 50)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(32, 71)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(11, 62)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(53, 62)
},
ButtonSchema.Up($"P{controller} Up", 32, 50),
ButtonSchema.Down($"P{controller} Down", 32, 71),
ButtonSchema.Left($"P{controller} Left", 11, 62),
ButtonSchema.Right($"P{controller} Right", 53, 62),
new ButtonSchema
{
Name = $"P{controller} L1",
@ -179,30 +159,10 @@ namespace BizHawk.Client.EmuHawk
DisplayName = $"Gamepad Player{controller}",
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(37, 55)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(37, 76)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(16, 67)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(58, 67)
},
ButtonSchema.Up($"P{controller} Up", 37, 55),
ButtonSchema.Down($"P{controller} Down", 37, 76),
ButtonSchema.Left($"P{controller} Left", 16, 67),
ButtonSchema.Right($"P{controller} Right", 58, 67),
new ButtonSchema
{
Name = $"P{controller} L1",
@ -276,30 +236,10 @@ namespace BizHawk.Client.EmuHawk
DisplayName = $"NeGcon Player{controller}",
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(36, 83)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(36, 104)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(15, 95)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(57, 95)
},
ButtonSchema.Up($"P{controller} Up", 36, 83),
ButtonSchema.Down($"P{controller} Down", 36, 104),
ButtonSchema.Left($"P{controller} Left", 15, 95),
ButtonSchema.Right($"P{controller} Right", 57, 95),
new ButtonSchema
{
Name = $"P{controller} Start",

View File

@ -56,30 +56,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(174, 90),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 12)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 56)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 34)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 34)
},
ButtonSchema.Up($"P{controller} Up", 14, 12),
ButtonSchema.Down($"P{controller} Down", 14, 56),
ButtonSchema.Left($"P{controller} Left", 2, 34),
ButtonSchema.Right($"P{controller} Right", 24, 34),
new ButtonSchema
{
Name = $"P{controller} B2",

View File

@ -49,32 +49,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(230, 100),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(34, 17)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(34, 61)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(22, 39)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(44, 39)
},
ButtonSchema.Up($"P{controller} Up", 34, 17),
ButtonSchema.Down($"P{controller} Down", 34, 61),
ButtonSchema.Left($"P{controller} Left", 22, 39),
ButtonSchema.Right($"P{controller} Right", 44, 39),
new ButtonSchema
{
Name = $"P{controller} Mode 1",

View File

@ -25,30 +25,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(174, 79),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controllerNum} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 12)
},
new ButtonSchema
{
Name = $"P{controllerNum} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 56)
},
new ButtonSchema
{
Name = $"P{controllerNum} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 34)
},
new ButtonSchema
{
Name = $"P{controllerNum} Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 34)
},
ButtonSchema.Up($"P{controllerNum} Up", 14, 12),
ButtonSchema.Down($"P{controllerNum} Down", 14, 56),
ButtonSchema.Left($"P{controllerNum} Left", 2, 34),
ButtonSchema.Right($"P{controllerNum} Right", 24, 34),
new ButtonSchema
{
Name = $"P{controllerNum} B",

View File

@ -74,30 +74,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(250, 100),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(34, 17)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(34, 61)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(22, 39)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(44, 39)
},
ButtonSchema.Up($"P{controller} Up", 34, 17),
ButtonSchema.Down($"P{controller} Down", 34, 61),
ButtonSchema.Left($"P{controller} Left", 22, 39),
ButtonSchema.Right($"P{controller} Right", 44, 39),
new ButtonSchema
{
Name = $"P{controller} Start",
@ -165,30 +145,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(458, 285),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(290, 77)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(290, 121)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(278, 99)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(300, 99)
},
ButtonSchema.Up($"P{controller} Up", 290, 77),
ButtonSchema.Down($"P{controller} Down", 290, 121),
ButtonSchema.Left($"P{controller} Left", 278, 99),
ButtonSchema.Right($"P{controller} Right", 300, 99),
new ButtonSchema
{
Name = $"P{controller} Start",
@ -328,18 +288,8 @@ namespace BizHawk.Client.EmuHawk
MinValue = 0,
MaxValue = 255
},
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(150, 20)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(150, 43)
},
ButtonSchema.Up($"P{controller} Up", 150, 20),
ButtonSchema.Down($"P{controller} Down", 150, 43),
new ButtonSchema
{
Name = $"P{controller} A",

View File

@ -33,30 +33,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(174, 90),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 12)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 56)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 34)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 34)
},
ButtonSchema.Up($"P{controller} Up", 14, 12),
ButtonSchema.Down($"P{controller} Down", 14, 56),
ButtonSchema.Left($"P{controller} Left", 2, 34),
ButtonSchema.Right($"P{controller} Right", 24, 34),
new ButtonSchema
{
Name = $"P{controller} B1",
@ -81,30 +61,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(174, 90),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 12)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 56)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 34)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 34)
},
ButtonSchema.Up($"P{controller} Up", 14, 12),
ButtonSchema.Down($"P{controller} Down", 14, 56),
ButtonSchema.Left($"P{controller} Left", 2, 34),
ButtonSchema.Right($"P{controller} Right", 24, 34),
new ButtonSchema
{
Name = $"P{controller} Start",

View File

@ -116,30 +116,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(200, 90),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(34, 17)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(34, 61)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(22, 39)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(44, 39)
},
ButtonSchema.Up($"P{controller} Up", 34, 17),
ButtonSchema.Down($"P{controller} Down", 34, 61),
ButtonSchema.Left($"P{controller} Left", 22, 39),
ButtonSchema.Right($"P{controller} Right", 44, 39),
new ButtonSchema
{
Name = $"P{controller} L",

View File

@ -45,30 +45,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(200, 100),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 12)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 56)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 34)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 34)
},
ButtonSchema.Up($"P{controller} Up", 14, 12),
ButtonSchema.Down($"P{controller} Down", 14, 56),
ButtonSchema.Left($"P{controller} Left", 2, 34),
ButtonSchema.Right($"P{controller} Right", 24, 34),
new ButtonSchema
{
Name = $"P{controller} Button 1",

View File

@ -23,30 +23,10 @@ namespace BizHawk.Client.EmuHawk
DefaultSize = new Size(222, 103),
Buttons = new[]
{
new ButtonSchema
{
Name = "L_Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(14, 36)
},
new ButtonSchema
{
Name = "L_Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(14, 80)
},
new ButtonSchema
{
Name = "L_Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 58)
},
new ButtonSchema
{
Name = "L_Right",
Icon = Properties.Resources.Forward,
Location = new Point(24, 58)
},
ButtonSchema.Up("L_Up", 14, 36),
ButtonSchema.Down("L_Down", 14, 80),
ButtonSchema.Left("L_Left", 2, 58),
ButtonSchema.Right("L_Right", 24, 58),
new ButtonSchema
{
Name = "B",
@ -69,30 +49,10 @@ namespace BizHawk.Client.EmuHawk
DisplayName = "S",
Location = new Point(74, 58)
},
new ButtonSchema
{
Name = "R_Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(188, 36)
},
new ButtonSchema
{
Name = "R_Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(188, 80)
},
new ButtonSchema
{
Name = "R_Left",
Icon = Properties.Resources.Back,
Location = new Point(176, 58)
},
new ButtonSchema
{
Name = "R_Right",
Icon = Properties.Resources.Forward,
Location = new Point(198, 58)
},
ButtonSchema.Up("R_Up", 188, 36),
ButtonSchema.Down("R_Down", 188, 80),
ButtonSchema.Left("R_Left", 176, 58),
ButtonSchema.Right("R_Right", 198, 58),
new ButtonSchema
{
Name = "L",
@ -119,7 +79,6 @@ namespace BizHawk.Client.EmuHawk
new ButtonSchema
{
Name = "Power",
DisplayName = "Power",
Location = new Point(10, 15)
}
}

View File

@ -28,30 +28,10 @@ namespace BizHawk.Client.EmuHawk
MaxSize = new Size(174, 74),
Buttons = new[]
{
new ButtonSchema
{
Name = $"P{controller} Up",
Icon = Properties.Resources.BlueUp,
Location = new Point(23, 15)
},
new ButtonSchema
{
Name = $"P{controller} Down",
Icon = Properties.Resources.BlueDown,
Location = new Point(23, 36)
},
new ButtonSchema
{
Name = $"P{controller} Left",
Icon = Properties.Resources.Back,
Location = new Point(2, 24)
},
new ButtonSchema
{
Name = $"P{controller} Right",
Icon = Properties.Resources.Forward,
Location = new Point(44, 24)
},
ButtonSchema.Up($"P{controller} Up", 23, 15),
ButtonSchema.Down($"P{controller} Down", 23, 36),
ButtonSchema.Left($"P{controller} Left", 2, 24),
ButtonSchema.Right($"P{controller} Right", 44, 24),
new ButtonSchema
{
Name = $"P{controller} Button",