summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/bus/neogeo_ctrl/ctrl.h
diff options
context:
space:
mode:
author Vas Crabb <vas@vastheman.com>2019-03-26 11:13:37 +1100
committer Vas Crabb <vas@vastheman.com>2019-03-26 11:13:37 +1100
commit97b67170277437131adf6ed4d60139c172529e4f (patch)
tree7a5cbf608f191075f1612b1af15832c206a3fe2d /src/devices/bus/neogeo_ctrl/ctrl.h
parentb380514764cf857469bae61c11143a19f79a74c5 (diff)
(nw) Clean up the mess on master
This effectively reverts b380514764cf857469bae61c11143a19f79a74c5 and c24473ddff715ecec2e258a6eb38960cf8c8e98e, restoring the state at 598cd5227223c3b04ca31f0dbc1981256d9ea3ff. Before pushing, please check that what you're about to push is sane. Check your local commit log and ensure there isn't anything out-of-place before pushing to mainline. When things like this happen, it wastes everyone's time. I really don't need this in a week when real work™ is busting my balls and I'm behind where I want to be with preparing for MAME release.
Diffstat (limited to 'src/devices/bus/neogeo_ctrl/ctrl.h')
-rw-r--r--src/devices/bus/neogeo_ctrl/ctrl.h32
1 files changed, 18 insertions, 14 deletions
diff --git a/src/devices/bus/neogeo_ctrl/ctrl.h b/src/devices/bus/neogeo_ctrl/ctrl.h
index aee534d61ad..bfe568d9b7e 100644
--- a/src/devices/bus/neogeo_ctrl/ctrl.h
+++ b/src/devices/bus/neogeo_ctrl/ctrl.h
@@ -42,6 +42,15 @@ class neogeo_control_port_device : public device_t, public device_slot_interface
{
public:
// construction/destruction
+ template <typename T>
+ neogeo_control_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt, bool const fixed)
+ : neogeo_control_port_device(mconfig, tag, owner, (uint32_t)0)
+ {
+ option_reset();
+ opts(*this);
+ set_default_option(dflt);
+ set_fixed(fixed);
+ }
neogeo_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
virtual ~neogeo_control_port_device();
@@ -83,6 +92,15 @@ class neogeo_ctrl_edge_port_device : public device_t, public device_slot_interfa
{
public:
// construction/destruction
+ template <typename T>
+ neogeo_ctrl_edge_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt, bool const fixed)
+ : neogeo_ctrl_edge_port_device(mconfig, tag, owner, (uint32_t)0)
+ {
+ option_reset();
+ opts(*this);
+ set_default_option(dflt);
+ set_fixed(fixed);
+ }
neogeo_ctrl_edge_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
virtual ~neogeo_ctrl_edge_port_device();
@@ -104,20 +122,6 @@ DECLARE_DEVICE_TYPE(NEOGEO_CONTROL_PORT, neogeo_control_port_device)
DECLARE_DEVICE_TYPE(NEOGEO_CTRL_EDGE_CONNECTOR, neogeo_ctrl_edge_port_device)
-//**************************************************************************
-// INTERFACE CONFIGURATION MACROS
-//**************************************************************************
-
-#define MCFG_NEOGEO_CONTROL_PORT_ADD(_tag, _slot_intf, _def_slot, _fixed) \
- MCFG_DEVICE_ADD(_tag, NEOGEO_CONTROL_PORT, 0) \
- MCFG_DEVICE_SLOT_INTERFACE(_slot_intf, _def_slot, _fixed)
-
-#define MCFG_NEOGEO_CONTROL_EDGE_CONNECTOR_ADD(_tag, _slot_intf, _def_slot, _fixed) \
- MCFG_DEVICE_ADD(_tag, NEOGEO_CTRL_EDGE_CONNECTOR, 0) \
- MCFG_DEVICE_SLOT_INTERFACE(_slot_intf, _def_slot, _fixed)
-
-
-
void neogeo_controls(device_slot_interface &device);
void neogeo_arc_edge(device_slot_interface &device);
void neogeo_arc_edge_fixed(device_slot_interface &device);