diff options
| author | 2019-09-14 15:27:30 -0400 | |
|---|---|---|
| committer | 2019-09-14 15:37:04 -0400 | |
| commit | 6fab7692981d7956fe400995e4774c9d007b215f (patch) | |
| tree | 33db51072448e42875ab5874549ca538a9add521 /src/emu/ioport.cpp | |
| parent | 2f39181ac1e093b42a6ff17b49013cfadb02e7a9 (diff) | |
PORT_CUSTOM simplification (nw)
- Remove both arguments from CUSTOM_INPUT_MEMBER (adding template parameters as necessary)
- Remove 'param' from PORT_CUSTOM_MEMBER and assume 'device' is DEVICE_SELF (use PORT_CUSTOM_DEVICE_MEMBER if it isn't)
- Replace PORT_CUSTOM_MEMBER with PORT_READ_LINE_MEMBER where applicable
Add implicit DEVICE_SELF variants of PORT_READ_LINE_DEVICE_MEMBER and PORT_WRITE_LINE_DEVICE_MEMBER (nw)
Remove ioport_field argument from PORT_CROSSHAIR_MAPPER (nw)
captflag, gmgalax: Separate driver classes from base (nw)
Diffstat (limited to 'src/emu/ioport.cpp')
| -rw-r--r-- | src/emu/ioport.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/emu/ioport.cpp b/src/emu/ioport.cpp index 58d076607d8..c65a5cb582b 100644 --- a/src/emu/ioport.cpp +++ b/src/emu/ioport.cpp @@ -597,7 +597,6 @@ ioport_field::ioport_field(ioport_port &port, ioport_type type, ioport_value def m_flags(0), m_impulse(0), m_name(name), - m_read_param(nullptr), m_write_param(0), m_digital_value(false), m_min(0), @@ -1210,7 +1209,7 @@ void ioport_field::crosshair_position(float &x, float &y, bool &gotx, bool &goty // apply custom mapping if necessary if (!m_crosshair_mapper.isnull()) - value = m_crosshair_mapper(*this, value); + value = m_crosshair_mapper(value); // handle X axis if (m_crosshair_axis == CROSSHAIR_AXIS_X) @@ -3189,7 +3188,7 @@ void dynamic_field::read(ioport_value &result) return; // call the callback to read a new value - ioport_value newval = m_field.m_read(m_field, m_field.m_read_param); + ioport_value newval = m_field.m_read(); m_oldval = newval; // merge in the bits (don't invert yet, as all digitals are inverted together) |
