|
|
| version 1.5, 2003/11/14 10:04:56 | version 1.6, 2003/11/24 07:40:02 |
|---|---|
| Line 133 void mackbd_callback(void) { | Line 133 void mackbd_callback(void) { |
| } | } |
| } | } |
| BOOL mackbd_keydown(int keycode) { | BOOL mackbd_keydown(int keycode, BOOL cmd) { |
| if (keycode == 0x6f) { | if (keycode == 0x6f) { |
| if (np2oscfg.F12COPY == 1) { | if (np2oscfg.F12COPY == 1) { |
| Line 145 BOOL mackbd_keydown(int keycode) { | Line 145 BOOL mackbd_keydown(int keycode) { |
| return(TRUE); | return(TRUE); |
| } | } |
| } | } |
| (void)cmd; | |
| return(FALSE); | return(FALSE); |
| } | } |
| Line 232 static const BYTE keymac[128] = { | Line 233 static const BYTE keymac[128] = { |
| // F2, rd, F1, ¢«, ¢ª, ¢, ¢¬, ; 0x78 | // F2, rd, F1, ¢«, ¢ª, ¢, ¢¬, ; 0x78 |
| 0x63,0x36,0x62,0x3b,0x3c,0x3d,0x3a, NC}; | 0x63,0x36,0x62,0x3b,0x3c,0x3d,0x3a, NC}; |
| // ÎӸ饡¼²¡²¼ | |
| static const BYTE keymac2[128] = { | |
| // £Á, £Ó, £Ä, £Æ, £È, £Ç, £Ú, £Ø ; 0x00 | |
| NC, NC, NC, NC,0x3f, NC, NC, NC, | |
| // £Ã, £Ö, , £Â, £Ñ, £×, £Å, £Ò ; 0x08 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // £Ù, £Ô, £±, £², £³, £´, £¶, £µ ; 0x10 | |
| NC, NC,0x62,0x63, 0x64,0x65,0x67,0x66, | |
| // ¡°, £¹, £·, ¡Ý, £¸, £°, ¡Î, £Ï ; 0x18 | |
| NC,0x6a,0x68, NC,0x69,0x6b, NC, NC, | |
| // £Õ, ¡÷, £É, £Ð, ret, £Ì, £Ê, ¡§ ; 0x20 | |
| NC, NC, NC, NC, NC,0x3e, NC, NC, | |
| // £Ë, ¡¨, ¡Ï, ¡¤, ¡¿, £Î, £Í, ¡¥ ; 0x28 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // TAB, SPC, , BS, , ESC, , apl ; 0x30 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // sft, cps, alt, ctl, , , , ; 0x38 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // , [.], , [*], , , [+], ; 0x40 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // , , , , ret, , [-], clr ; 0x48 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // , [=], [0], [1], [2], [3], [4], [5] ; 0x50 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // [6], [7], , [8], [9], ¡ï, ¡², [,] ; 0x58 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // F5, F6, F7, F3, F8, F9, , F11 ; 0x60 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // , F13, , F14, , F10, , F12 ; 0x68 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // , F15, hlp, hom, ru, del, F4, end ; 0x70 | |
| NC, NC, NC, NC, NC,0x38, NC, NC, | |
| // F2, rd, F1, ¢«, ¢ª, ¢, ¢¬, ; 0x78 | |
| NC, NC, NC, NC, NC, NC, NC, NC}; | |
| typedef struct { | typedef struct { |
| UINT32 tick; | UINT32 tick; |
| UINT16 shift; | UINT16 shift; |
| Line 278 void mackbd_callback(void) { | Line 314 void mackbd_callback(void) { |
| } | } |
| } | } |
| BOOL mackbd_keydown(int keycode) { | BOOL mackbd_keydown(int keycode, BOOL cmd) { |
| BYTE data; | BYTE data; |
| Line 292 BOOL mackbd_keydown(int keycode) { | Line 328 BOOL mackbd_keydown(int keycode) { |
| } | } |
| } | } |
| else if (keycode < 0x80) { | else if (keycode < 0x80) { |
| data = keymac[keycode]; | if (!cmd) { |
| data = keymac[keycode]; | |
| } | |
| else { | |
| data = keymac2[keycode]; | |
| } | |
| } | } |
| if (data != NC) { | if (data != NC) { |
| keystat_senddata(data); | keystat_senddata(data); |
| Line 306 BOOL mackbd_keydown(int keycode) { | Line 347 BOOL mackbd_keydown(int keycode) { |
| BOOL mackbd_keyup(int keycode) { | BOOL mackbd_keyup(int keycode) { |
| BYTE data; | BYTE data; |
| BOOL ret; | |
| data = NC; | data = NC; |
| ret = FALSE; | |
| if (keycode == 0x6f) { | if (keycode == 0x6f) { |
| if (np2oscfg.F12COPY == 1) { | if (np2oscfg.F12COPY == 1) { |
| data = 0x61; | data = 0x61; |
| Line 318 BOOL mackbd_keyup(int keycode) { | Line 361 BOOL mackbd_keyup(int keycode) { |
| } | } |
| else if (keycode < 0x80) { | else if (keycode < 0x80) { |
| data = keymac[keycode]; | data = keymac[keycode]; |
| if (data != NC) { | |
| keystat_senddata(data | 0x80); | |
| ret = TRUE; | |
| } | |
| data = keymac2[keycode]; | |
| } | } |
| if (data != NC) { | if (data != NC) { |
| keystat_senddata(data | 0x80); | keystat_senddata(data | 0x80); |
| return(TRUE); | ret = TRUE; |
| } | |
| else { | |
| return(FALSE); | |
| } | } |
| return(ret); | |
| } | } |
| void mackbd_activate(BOOL active) { | void mackbd_activate(BOOL active) { |
| Line 340 void mackbd_activate(BOOL active) { | Line 386 void mackbd_activate(BOOL active) { |
| #endif | #endif |
| #if 0 | |
| // ÎӸ饡¼²¡²¼ | |
| static const BYTE keymac2[128] = { | |
| // £Á, £Ó, £Ä, £Æ, £È, £Ç, £Ú, £Ø ; 0x00 | |
| NC, NC, NC, NC,0x3f, NC, NC, NC, | |
| // £Ã, £Ö, , £Â, £Ñ, £×, £Å, £Ò ; 0x08 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // £Ù, £Ô, £±, £², £³, £´, £¶, £µ ; 0x10 | |
| NC, NC,0x62,0x63, 0x64,0x65,0x67,0x66, | |
| // ¡°, £¹, £·, ¡Ý, £¸, £°, ¡Î, £Ï ; 0x18 | |
| NC,0x6a,0x68, NC,0x69,0x6b, NC, NC, | |
| // £Õ, ¡÷, £É, £Ð, ret, £Ì, £Ê, ¡§ ; 0x20 | |
| NC, NC, NC, NC, NC,0x3e, NC, NC, | |
| // £Ë, ¡¨, ¡Ï, ¡¤, ¡¿, £Î, £Í, ¡¥ ; 0x28 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // TAB, SPC, , BS, , ESC, , apl ; 0x30 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // sft, cps, alt, ctl, , , , ; 0x38 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // , [.], , [*], , , [+], ; 0x40 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // , , , , ret, , [-], clr ; 0x48 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // , [=], [0], [1], [2], [3], [4], [5] ; 0x50 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // [6], [7], , [8], [9], ¡ï, ¡², [,] ; 0x58 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // F5, F6, F7, F3, F8, F9, , F11 ; 0x60 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // , F13, , F14, , F10, , F12 ; 0x68 | |
| NC, NC, NC, NC, NC, NC, NC, NC, | |
| // , F15, hlp, hom, ru, del, F4, end ; 0x70 | |
| NC, NC, NC, NC, NC,0x38, NC, NC, | |
| // F2, rd, F1, ¢«, ¢ª, ¢, ¢¬, ; 0x78 | |
| NC, NC, NC, NC, NC, NC, NC, NC}; | |
| #endif |