#include <windows.h>
#include "resources.h"

#define KEY_A 1
#define KEY_B 2
#define KEY_C 3
#define KEY_D 4
#define KEY_E 5
#define KEY_F 6
#define KEY_G 7
#define KEY_H 8
#define KEY_I 9
#define KEY_J 10
#define KEY_K 11
#define KEY_L 12
#define KEY_M 13
#define KEY_N 14
#define KEY_O 15
#define KEY_P 16
#define KEY_Q 17
#define KEY_R 18
#define KEY_S 19
#define KEY_T 20
#define KEY_U 21
#define KEY_V 22
#define KEY_W 23
#define KEY_X 24
#define KEY_Y 25
#define KEY_Z 26
#define KEY_0 27
#define KEY_1 28
#define KEY_2 29
#define KEY_3 30
#define KEY_4 31
#define KEY_5 32
#define KEY_6 33
#define KEY_7 34
#define KEY_8 35
#define KEY_9 36
#define KEY_0_PAD 37
#define KEY_1_PAD 38
#define KEY_2_PAD 39
#define KEY_3_PAD 40
#define KEY_4_PAD 41
#define KEY_5_PAD 42
#define KEY_6_PAD 43
#define KEY_7_PAD 44
#define KEY_8_PAD 45
#define KEY_9_PAD 46
#define KEY_F1 47
#define KEY_F2 48
#define KEY_F3 49
#define KEY_F4 50
#define KEY_F5 51
#define KEY_F6 52
#define KEY_F7 53
#define KEY_F8 54
#define KEY_F9 55
#define KEY_F10 56
#define KEY_F11 57
#define KEY_F12 58
#define KEY_ESC 59
#define KEY_TILDE 60
#define KEY_MINUS 61
#define KEY_EQUALS 62
#define KEY_BACKSPACE 63
#define KEY_TAB 64
#define KEY_OPENBRACE 65
#define KEY_CLOSEBRACE 66
#define KEY_ENTER 67
#define KEY_COLON 68
#define KEY_QUOTE 69
#define KEY_BACKSLASH 70
#define KEY_BACKSLASH2 71
#define KEY_COMMA 72
#define KEY_STOP 73
#define KEY_SLASH 74
#define KEY_SPACE 75
#define KEY_INSERT 76
#define KEY_DEL 77
#define KEY_HOME 78
#define KEY_END 79
#define KEY_PGUP 80
#define KEY_PGDN 81
#define KEY_LEFT 82
#define KEY_RIGHT 83
#define KEY_UP 84
#define KEY_DOWN 85
#define KEY_SLASH_PAD 86
#define KEY_ASTERISK 87
#define KEY_MINUS_PAD 88
#define KEY_PLUS_PAD 89
#define KEY_DEL_PAD 90
#define KEY_ENTER_PAD 91
#define KEY_COLON2 101
#define KEY_EQUALS_PAD 103
#define KEY_BACKQUOTE 104
#define KEY_SEMICOLON 105

#define KEY_LSHIFT 115
#define KEY_RSHIFT 116
#define KEY_LCONTROL 117
#define KEY_RCONTROL 118
#define KEY_ALT 119
#define KEY_ALTGR 120
#define KEY_LWIN 121
#define KEY_RWIN 122
#define KEY_MENU 123
#define KEY_SCRLOCK 124
#define KEY_NUMLOCK 125
#define KEY_CAPSLOCK 126

allegro_icon ICON elkulator.ico

MainMenu MENU DISCARDABLE
BEGIN
        POPUP "&File"
        BEGIN
                MENUITEM "&Reset",      IDM_FILE_RESET
                MENUITEM SEPARATOR
                MENUITEM "&Load state", IDM_FILE_LSTATE
                MENUITEM "&Save state", IDM_FILE_SSTATE
                MENUITEM SEPARATOR
                MENUITEM "E&xit",       IDM_FILE_EXIT
        END
        POPUP "&Tape"
        BEGIN
                MENUITEM "&Load tape...",IDM_TAPE_LOAD
                MENUITEM SEPARATOR
                MENUITEM "&Rewind tape", IDM_TAPE_REWIND
                MENUITEM SEPARATOR
                POPUP "&Speed"
                BEGIN
                        MENUITEM "&Normal",IDM_SPD_NORMAL
                        MENUITEM "&Fast",IDM_SPD_FAST
                        MENUITEM "&Really Fast",IDM_SPD_REALLY
                END
        END
        POPUP "&Disc"
        BEGIN
//                MENUITEM "&Autoboot disc :0/2...",     IDM_DISC_AUTOBOOT
//                MENUITEM SEPARATOR
                MENUITEM "Load disc :&0/2...",     IDM_DISC_LOAD_0
                MENUITEM "Load disc :&1/3...",     IDM_DISC_LOAD_1
                MENUITEM SEPARATOR
                MENUITEM "Eject disc :0/2",        IDM_DISC_EJECT_0
                MENUITEM "Eject disc :1/3",        IDM_DISC_EJECT_1
                MENUITEM SEPARATOR
                MENUITEM "New disc :0/2",          IDM_DISC_NEW_0
                MENUITEM "New disc :1/3",          IDM_DISC_NEW_1
                MENUITEM SEPARATOR
                MENUITEM "Write protect disc :0/2",IDM_DISC_WPROT_0
                MENUITEM "Write protect disc :1/3",IDM_DISC_WPROT_1
                MENUITEM SEPARATOR
                MENUITEM "Default write protect",  IDM_DISC_WPROT_D
        END
        POPUP "&ROM"
        BEGIN
                MENUITEM "Load ROM Cartridge &1...",IDM_ROM_LOAD1
                MENUITEM "Load ROM Cartridge &2...",IDM_ROM_LOAD2
                MENUITEM SEPARATOR
                MENUITEM "&Unload ROM Cartridges...",IDM_ROM_UNLOAD
        END
        POPUP "&Hardware"
        BEGIN
                POPUP "&Video"
                BEGIN
                        POPUP "&Display type"
                        BEGIN
                                MENUITEM "&Scanlines",IDM_VIDEO_SCANLINES
                                MENUITEM "&Line doubling",IDM_VIDEO_LINEDBL
                                MENUITEM "&2xSaI",IDM_VIDEO_2XSAI
                                MENUITEM "Scale2&X",IDM_VIDEO_SCALE2X
                                MENUITEM "Super&Eagle",IDM_VIDEO_EAGLE
                                MENUITEM "&PAL filter",IDM_VIDEO_PAL
                        END
                        MENUITEM "&Fullscreen",IDM_VIDEO_FULLSCREEN
                        MENUITEM "&Resizeable window",IDM_VIDEO_RESIZE
                END
                POPUP "&Disc"
                BEGIN
                        MENUITEM "&Plus 3 enable",IDM_DISC_PLUS3
                        MENUITEM "&ADFS enable",  IDM_DISC_ADFS
                        MENUITEM "&DFS enable",   IDM_DISC_DFS
                END
                POPUP "&Memory"
                BEGIN
                        MENUITEM "&Elektuur/Slogger turbo board",IDM_OTHER_TURBO
                        MENUITEM SEPARATOR
                        MENUITEM "&Slogger/Jafa Master RAM board",IDM_OTHER_MRB
                        POPUP "&Master RAM board mode"
                        BEGIN
                                MENUITEM "&Off",   IDM_MRB_OFF
                                MENUITEM "&Turbo", IDM_MRB_TURBO
                                MENUITEM "&Shadow",IDM_MRB_SHADOW
                        END
                END
                POPUP "&Sound"
                BEGIN
                        MENUITEM "&Internal sound output",IDM_OTHER_SNDIN
                        MENUITEM "&CSS Sound Expansion",IDM_OTHER_SNDEX
                        MENUITEM "&Disc drive noise",    IDM_SOUND_DDNOISE
                        MENUITEM "&Tape noise",    IDM_SOUND_TNOISE
                        MENUITEM SEPARATOR
                        POPUP "Disc drive &type"
                        BEGIN
                                MENUITEM "&5.25",IDM_DDT_525
                                MENUITEM "&3.5", IDM_DDT_35
                        END
                        POPUP "Disc drive &volume"
                        BEGIN
                                MENUITEM "&33%", IDM_DDV_33
                                MENUITEM "&66%", IDM_DDV_66
                                MENUITEM "&100%", IDM_DDV_100
                        END
                END
                POPUP "&Joystick"
                BEGIN
                        MENUITEM "&Plus 1 interface",IDM_OTHER_PLUS1
                        MENUITEM "&First Byte interface",IDM_OTHER_FBJOY
                END
                POPUP "&Keyboard"
                BEGIN
                        MENUITEM "&Redefine keyboard",IDM_OTHER_RDKEY
                        MENUITEM "Restore &default layout",IDM_OTHER_KEYDF
                END
        END
        POPUP "&Misc"
        BEGIN
                MENUITEM "&Save screenshot", IDM_SCRSHOT
                MENUITEM SEPARATOR
                MENUITEM "&Debugger", IDM_DEBUGGER
                MENUITEM "&Break",    IDM_BREAK
        END
END

Redefine DIALOG 20, 20, 272, 116
STYLE WS_CAPTION | WS_THICKFRAME
CAPTION "Redefine keys"
FONT 6, "MS Sans Serif"
BEGIN
   PUSHBUTTON "ESC", Button1+KEY_ESC, 16, 8, 16, 15 , WS_TABSTOP
   PUSHBUTTON "1", Button1+KEY_1, 32, 8, 16, 15 , WS_TABSTOP
   PUSHBUTTON "2", Button1+KEY_2, 48, 8, 16, 15 , WS_TABSTOP
   PUSHBUTTON "3", Button1+KEY_3, 64, 8, 16, 15 , WS_TABSTOP
   PUSHBUTTON "4", Button1+KEY_4, 80, 8, 16, 15 , WS_TABSTOP
   PUSHBUTTON "5", Button1+KEY_5, 96, 8, 16, 15 , WS_TABSTOP
   PUSHBUTTON "6", Button1+KEY_6, 112, 8, 16, 15 , WS_TABSTOP
   PUSHBUTTON "7", Button1+KEY_7, 128, 8, 16, 15 , WS_TABSTOP
   PUSHBUTTON "8", Button1+KEY_8, 144, 8, 16, 15 , WS_TABSTOP
   PUSHBUTTON "9", Button1+KEY_9, 160, 8, 16, 15 , WS_TABSTOP
   PUSHBUTTON "0", Button1+KEY_0, 176, 8, 16, 15 , WS_TABSTOP
   PUSHBUTTON "=", Button1+KEY_MINUS, 192, 8, 16, 15 , WS_TABSTOP
   PUSHBUTTON "LEFT", Button1+KEY_LEFT, 208, 8, 16, 15 , WS_TABSTOP
   PUSHBUTTON "RGHT", Button1+KEY_RIGHT, 224, 8, 16, 15 , WS_TABSTOP
   PUSHBUTTON "CAPS", Button1+KEY_CAPSLOCK, 24, 24, 24, 15 , WS_TABSTOP
   PUSHBUTTON "Q", Button1+KEY_Q, 40, 24, 16, 15 , WS_TABSTOP
   PUSHBUTTON "W", Button1+KEY_W, 56, 24, 16, 15 , WS_TABSTOP
   PUSHBUTTON "E", Button1+KEY_E, 72, 24, 16, 15 , WS_TABSTOP
   PUSHBUTTON "R", Button1+KEY_R, 88, 24, 16, 15 , WS_TABSTOP
   PUSHBUTTON "T", Button1+KEY_T, 104, 24, 16, 15 , WS_TABSTOP
   PUSHBUTTON "Y", Button1+KEY_Y, 120, 24, 16, 15 , WS_TABSTOP
   PUSHBUTTON "U", Button1+KEY_U, 136, 24, 16, 15 , WS_TABSTOP
   PUSHBUTTON "I", Button1+KEY_I, 152, 24, 16, 15 , WS_TABSTOP
   PUSHBUTTON "O", Button1+KEY_O, 168, 24, 16, 15 , WS_TABSTOP
   PUSHBUTTON "P", Button1+KEY_P, 184, 24, 16, 15 , WS_TABSTOP
   PUSHBUTTON "UP", Button1+KEY_UP, 200, 24, 16, 15 , WS_TABSTOP
   PUSHBUTTON "DOWN", Button1+KEY_DOWN, 216, 24, 16, 15 , WS_TABSTOP
   PUSHBUTTON "COPY", Button1+KEY_END, 232, 24, 16, 15 , WS_TABSTOP
   PUSHBUTTON "CTRL", Button1+KEY_LCONTROL, 28, 40, 16, 15 , WS_TABSTOP
   PUSHBUTTON "A", Button1+KEY_A, 44, 40, 16, 15 , WS_TABSTOP
   PUSHBUTTON "S", Button1+KEY_S, 60, 40, 16, 15 , WS_TABSTOP
   PUSHBUTTON "D", Button1+KEY_D, 76, 40, 16, 15 , WS_TABSTOP
   PUSHBUTTON "F", Button1+KEY_F, 92, 40, 16, 15 , WS_TABSTOP
   PUSHBUTTON "G", Button1+KEY_G, 108, 40, 16, 15 , WS_TABSTOP
   PUSHBUTTON "H", Button1+KEY_H, 124, 40, 16, 15 , WS_TABSTOP
   PUSHBUTTON "J", Button1+KEY_J, 140, 40, 16, 15 , WS_TABSTOP
   PUSHBUTTON "K", Button1+KEY_K, 156, 40, 16, 15 , WS_TABSTOP
   PUSHBUTTON "L", Button1+KEY_L, 172, 40, 16, 15 , WS_TABSTOP
   PUSHBUTTON ";", Button1+KEY_SEMICOLON, 188, 40, 16, 15 , WS_TABSTOP
   PUSHBUTTON ":", Button1+KEY_QUOTE, 204, 40, 16, 15 , WS_TABSTOP
   PUSHBUTTON "RET", Button1+KEY_ENTER, 220, 40, 32, 15 , WS_TABSTOP
   PUSHBUTTON "SHIFT", Button1+KEY_LSHIFT, 28, 56, 24, 15 , WS_TABSTOP
   PUSHBUTTON "Z", Button1+KEY_Z, 52, 56, 16, 15 , WS_TABSTOP
   PUSHBUTTON "X", Button1+KEY_X, 68, 56, 16, 15 , WS_TABSTOP
   PUSHBUTTON "C", Button1+KEY_C, 84, 56, 16, 15 , WS_TABSTOP
   PUSHBUTTON "V", Button1+KEY_V, 100, 56, 16, 15 , WS_TABSTOP
   PUSHBUTTON "B", Button1+KEY_B, 116, 56, 16, 15 , WS_TABSTOP
   PUSHBUTTON "N", Button1+KEY_N, 132, 56, 16, 15 , WS_TABSTOP
   PUSHBUTTON "M", Button1+KEY_M, 148, 56, 16, 15 , WS_TABSTOP
   PUSHBUTTON ",", Button1+KEY_COMMA, 164, 56, 16, 15 , WS_TABSTOP
   PUSHBUTTON ".", Button1+KEY_STOP, 180, 56, 16, 15 , WS_TABSTOP
   PUSHBUTTON "/", Button1+KEY_SLASH, 196, 56, 16, 15 , WS_TABSTOP
   PUSHBUTTON "SHIFT", Button1+KEY_RSHIFT, 212, 56, 24, 15 , WS_TABSTOP
   PUSHBUTTON "DEL", Button1+KEY_DEL, 236, 56, 16, 15 , WS_TABSTOP
   PUSHBUTTON "SPACE", Button1+KEY_SPACE, 68, 72, 128, 15 , WS_TABSTOP

   PUSHBUTTON "OK", IDOK, 96, 96, 32, 16, WS_TABSTOP
   PUSHBUTTON "Cancel", IDCANCEL, 136, 96, 32, 16, WS_TABSTOP
END
