28 |
|
|
29 |
|
#include "sysdeps.h" |
30 |
|
#include "cpu_emulation.h" |
31 |
– |
#include "main.h" |
31 |
|
#include "emul_op.h" |
32 |
+ |
#include "main.h" |
33 |
+ |
#include "prefs.h" |
34 |
|
#include "video.h" |
35 |
|
#include "adb.h" |
36 |
|
|
58 |
|
static uint8 key_reg_2[2] = {0xff, 0xff}; // Keyboard ADB register 2 |
59 |
|
static uint8 key_reg_3[2] = {0x62, 0x05}; // Keyboard ADB register 3 |
60 |
|
|
61 |
+ |
static uint8 m_keyboard_type = 0x05; |
62 |
+ |
|
63 |
|
// ADB mouse motion lock (for platforms that use separate input thread) |
64 |
|
static B2_mutex *mouse_lock; |
65 |
|
|
71 |
|
void ADBInit(void) |
72 |
|
{ |
73 |
|
mouse_lock = B2_create_mutex(); |
74 |
+ |
m_keyboard_type = (uint8)PrefsFindInt32("keyboardtype"); |
75 |
+ |
key_reg_3[1] = m_keyboard_type; |
76 |
|
} |
77 |
|
|
78 |
|
|
104 |
|
key_reg_2[0] = 0xff; |
105 |
|
key_reg_2[1] = 0xff; |
106 |
|
key_reg_3[0] = 0x62; |
107 |
< |
key_reg_3[1] = 0x05; |
107 |
> |
key_reg_3[1] = m_keyboard_type; |
108 |
|
return; |
109 |
|
} |
110 |
|
|