diff options
Diffstat (limited to 'src/devices/video/crt9021.h')
-rw-r--r-- | src/devices/video/crt9021.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/devices/video/crt9021.h b/src/devices/video/crt9021.h index 65de1032a64..2a7e513fdf2 100644 --- a/src/devices/video/crt9021.h +++ b/src/devices/video/crt9021.h @@ -38,6 +38,10 @@ #define CRT9021_DRAW_CHARACTER_MEMBER(_name) void _name(bitmap_rgb32 &bitmap, int y, int x, uint8_t video, int intout) +#define MCFG_CRT9021_DRAW_CHARACTER_CALLBACK_OWNER(_class, _method) \ + downcast<crt9021_device &>(*device).set_display_callback(crt9021_device::draw_character_delegate(&_class::_method, #_class "::" #_method, this)); + + //************************************************************************** // TYPE DEFINITIONS //************************************************************************** @@ -53,7 +57,7 @@ public: // construction/destruction crt9021_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); - template <typename... T> void set_display_callback(T &&... args) { m_display_cb = draw_character_delegate(std::forward<T>(args)...); } + template <typename Object> void set_display_callback(Object &&cb) { m_display_cb = std::forward<Object>(cb); } void write(uint8_t data) { m_data = data; } DECLARE_WRITE8_MEMBER( write ) { write(data); } |