MCPcopy Create free account
hub / github.com/BlitterStudio/amiberry / mousehack_enable

Function mousehack_enable

src/inputdevice.cpp:2592–2611  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2590}
2591
2592static bool mousehack_enable (void)
2593{
2594 int mode;
2595
2596 if (uae_boot_rom_type <= 0 || currprefs.input_tablet == TABLET_OFF)
2597 return false;
2598 if (mousehack_address && mousehack_enabled)
2599 return true;
2600 mode = 0x80;
2601 if (currprefs.input_tablet == TABLET_MOUSEHACK)
2602 mode |= 1;
2603 if (inputdevice_is_tablet () > 0)
2604 mode |= 2;
2605 if (mousehack_address && rtarea_bank.baseaddr) {
2606 write_log (_T("Mouse driver enabled (%s)\n"), ((mode & 3) == 3 ? _T("tablet+mousehack") : ((mode & 3) == 2) ? _T("tablet") : _T("mousehack")));
2607 put_byte_host(mousehack_address + MH_E, mode);
2608 mousehack_enabled = true;
2609 }
2610 return true;
2611}
2612
2613static void inputdevice_update_tablet_params(void)
2614{

Callers 6

input_mousehack_statusFunction · 0.85
inputdevice_tabletFunction · 0.85
inputdevice_mh_absFunction · 0.85
inputdevice_mh_abs_v36Function · 0.85
inputdevice_resetFunction · 0.85

Calls 3

inputdevice_is_tabletFunction · 0.85
put_byte_hostFunction · 0.85
write_logFunction · 0.70

Tested by

no test coverage detected