moving XInitDevices to ArchHooks so devices are initialized before usb manager initializes

This commit is contained in:
Vecais Dumais Laacis
2007-08-12 08:14:39 +00:00
parent 5d166e83ec
commit f341130012
2 changed files with 8 additions and 2 deletions
@@ -111,6 +111,12 @@ void EnableExtraRAM()
WRITEMSRREG( 0x02FF, regVal );
}
void InitDevices()
{
XDEVICE_PREALLOC_TYPE xdpt[] = {{XDEVICE_TYPE_GAMEPAD, 4}, {XDEVICE_TYPE_MEMORY_UNIT, 2}};
XInitDevices( sizeof(xdpt) / sizeof(XDEVICE_PREALLOC_TYPE), xdpt );
}
ArchHooks_Xbox::ArchHooks_Xbox()
{
_set_new_handler(NoMemory);
@@ -125,6 +131,8 @@ ArchHooks_Xbox::ArchHooks_Xbox()
SetupNetwork();
EnableExtraRAM();
InitDevices();
}
static RString XLangID( DWORD Lang )
@@ -38,8 +38,6 @@ InputHandler_Xbox::InputHandler_Xbox()
//
// Init joysticks
//
XDEVICE_PREALLOC_TYPE xdpt[] = {{XDEVICE_TYPE_GAMEPAD, 4}, {XDEVICE_TYPE_MEMORY_UNIT, 2}};
XInitDevices( sizeof(xdpt) / sizeof(XDEVICE_PREALLOC_TYPE), xdpt );
ZeroMemory( joysticks, sizeof(joysticks) );
getHandles();