From aaf24b65e5d12c87a0c515bcc6acbf74f00b1809 Mon Sep 17 00:00:00 2001 From: Sjoerd van der Berg Date: Sat, 18 Jan 2003 11:32:18 +0000 Subject: [PATCH] Support to enable/disable the disney. Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@639 --- src/hardware/disney.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/hardware/disney.cpp b/src/hardware/disney.cpp index 0e2291c8..3631f25a 100644 --- a/src/hardware/disney.cpp +++ b/src/hardware/disney.cpp @@ -20,8 +20,6 @@ static struct { Bit8u control; Bit8u buffer[DISNEY_SIZE]; Bitu used; - bool enabled; - Bit8u delay; MIXER_Channel * chan; } disney; @@ -40,7 +38,7 @@ static void disney_write(Bit32u port,Bit8u val) { disney.buffer[disney.used++]=disney.data; } } - if (val&0x10) LOG_DEBUG("IRQ Enabled"); + if (val&0x10) LOG_DEBUG("DISNEY:Parallel IRQ Enabled"); disney.control=val; break; } @@ -83,6 +81,10 @@ static void DISNEY_CallBack(Bit8u * stream,Bit32u len) { void DISNEY_Init(Section* sec) { + + Section_prop * section=static_cast(sec); + if(!section->Get_bool("enabled")) return; + IO_RegisterWriteHandler(DISNEY_BASE,disney_write,"DISNEY"); IO_RegisterWriteHandler(DISNEY_BASE+1,disney_write,"DISNEY"); IO_RegisterWriteHandler(DISNEY_BASE+2,disney_write,"DISNEY");