From 1e88333178b63ee0d5b914e181b19b3b161f807b Mon Sep 17 00:00:00 2001 From: Aaron Giles Date: Thu, 3 Feb 2011 07:52:45 +0000 Subject: Converted attotime to a class, with proper operators. Removed old global functions which are now superceded by the operators and methods on the class. [Aaron Giles] Required mappings are: attotime_make(a,b) => attotime(a,b) attotime_to_double(t) => t.as_double() double_to_attotime(d) => attotime::from_double(d) attotime_to_attoseconds(t) => t.as_attoseconds() attotime_to_ticks(t,f) => t.as_ticks(f) ticks_to_attotime(t,f) => attotime::from_ticks(t,f) attotime_add(a,b) => a + b attotime_add_attoseconds(a,b) => a + attotime(0, b) attotime_sub(a,b) => a - b attotime_sub_attoseconds(a,b) => a - attotime(0, b) attotime_compare(a,b) == 0 => a == b attotime_compare(a,b) != 0 => a != b attotime_compare(a,b) < 0 => a < b attotime_compare(a,b) <= 0 => a <= b attotime_compare(a,b) > 0 => a > b attotime_compare(a,b) >= 0 => a >= b attotime_mul(a,f) => a * f attotime_div(a,f) => a / f attotime_min(a,b) => min(a,b) attotime_max(a,b) => max(a,b) attotime_is_never(t) => t.is_never() attotime_string(t,p) => t.as_string(p) In addition, some existing #defines still exist but will go away: attotime_zero => attotime::zero attotime_never => attotime::never ATTOTIME_IN_SEC(s) => attotime::from_seconds(s) ATTOTIME_IN_MSEC(m) => attotime::from_msec(m) ATTOTIME_IN_USEC(u) => attotime::from_usec(u) ATTOTIME_IN_NSEC(n) => attotime::from_nsec(n) ATTOTIME_IN_HZ(h) => attotime::from_hz(h) --- src/emu/machine/f3853.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/emu/machine/f3853.c') diff --git a/src/emu/machine/f3853.c b/src/emu/machine/f3853.c index e9aa8da6b5d..aaac51edfc7 100644 --- a/src/emu/machine/f3853.c +++ b/src/emu/machine/f3853.c @@ -188,7 +188,7 @@ void f3853_device::f3853_set_interrupt_request_line() void f3853_device::f3853_timer_start(UINT8 value) { - attotime period = (value != 0xff) ? attotime_mul(ATTOTIME_IN_HZ(clock()), m_value_to_cycle[value]*31) : attotime_never; + attotime period = (value != 0xff) ? attotime::from_hz(clock()) * (m_value_to_cycle[value]*31) : attotime::never; timer_adjust_oneshot(m_timer, period, 0); } -- cgit v1.2.3-70-g09d2