#include "src/core/hotkeys.hpp"

const char *const Hotkeys::ConfigNames[(ubyte)Hotkey::NUM_HOTKEYS] = {
	/* AnalogUp,           */ "input_player1_l_y_minus",
	/* AnalogDown,         */ "input_player1_l_y_plus",
	/* AnalogLeft,         */ "input_player1_l_x_minus",
	/* AnalogRight,        */ "input_player1_l_x_plus",
#ifdef LEGACY_MAPPINGS
	/* CUp,                */ "input_player1_r_y_minus",
	/* CDown,              */ "input_player1_r_y_plus",
	/* CLeft,              */ "input_player1_r_x_minus",
	/* CRight,             */ "input_player1_r_x_plus",
	/* DPadUp,             */ "input_player1_up",
	/* DPadDown,           */ "input_player1_down",
	/* DPadLeft,           */ "input_player1_left",
	/* DPadRight,          */ "input_player1_right",
	/* ButtonA,            */ "input_player1_b",
	/* ButtonB,            */ "input_player1_y",
	/* TriggerL,           */ "input_player1_l",
	/* TriggerZ,           */ "input_player1_l2",
	/* TriggerR,           */ "input_player1_r",
#else
	/* CUp,                */ "input_player1_x",
	/* CDown,              */ "input_player1_a",
	/* CLeft,              */ "input_player1_l",
	/* CRight,             */ "input_player1_r",
	/* DPadUp,             */ "input_player1_up",
	/* DPadDown,           */ "input_player1_down",
	/* DPadLeft,           */ "input_player1_left",
	/* DPadRight,          */ "input_player1_right",
	/* ButtonA,            */ "input_player1_b",
	/* ButtonB,            */ "input_player1_y",
	/* TriggerL,           */ "input_player1_select",
	/* TriggerZ,           */ "input_player1_l2",
	/* TriggerR,           */ "input_player1_r2",
#endif
	/* Start,              */ "input_player1_start",
	/* ButtonX,            */ "input_player1_l3",
	/* ButtonY,            */ "input_player1_r3",
	/* SaveState,          */ "input_save_state",
	/* LoadState,          */ "input_load_state",
	/* PrevState,          */ "input_state_slot_decrease",
	/* NextState,          */ "input_state_slot_increase",
	/* PrevCheat,          */ "input_cheat_index_minus",
	/* NextCheat,          */ "input_cheat_index_plus",
	/* ToggleCheat,        */ "input_cheat_toggle",
	/* ToggleFps,          */ "input_fps_toggle",
	/* Pause,              */ "input_pause_toggle",
	/* FrameAdvance,       */ "input_frame_advance",
	/* FastForward,        */ "input_hold_fast_forward",
	/* ToggleFastForward,  */ "input_toggle_fast_forward",
	/* SlowMotion,         */ "input_hold_slowmotion",
	/* ToggleSlowMotion,   */ "input_toggle_slowmotion",
	/* Rewind,             */ "input_rewind",
	/* Quit,               */ "input_exit_emulator",
	/* HardReset,          */ "input_reset",
	/* ToggleFullscreen,   */ "input_toggle_fullscreen",
	/* RetroMenu,          */ "input_menu_toggle",
	/* RecordVideo,        */ "input_movie_record_toggle",
	/* RecordInputs,       */ "input_recording_toggle",
	/* Screenshot,         */ "input_screenshot",
	/* VolumeUp,           */ "input_volume_up",
	/* VolumeDown,         */ "input_volume_down",
	/* Mute                */ "input_audio_mute",
	/* GrabMouse           */ "input_grab_mouse_toggle"
};


const KeyId Hotkeys::Default[(ubyte)Hotkey::NUM_HOTKEYS] = {
	/* AnalogUp,           */ KeyId::W,
	/* AnalogDown,         */ KeyId::S,
	/* AnalogLeft,         */ KeyId::A,
	/* AnalogRight,        */ KeyId::D,
	/* CUp,                */ KeyId::ArrowUp,
	/* CDown,              */ KeyId::ArrowDown,
	/* CLeft,              */ KeyId::ArrowLeft,
	/* CRight,             */ KeyId::ArrowRight,
	/* DPadUp,             */ KeyId::Numpad8,
	/* DPadDown,           */ KeyId::Numpad2,
	/* DPadLeft,           */ KeyId::Numpad4,
	/* DPadRight,          */ KeyId::Numpad6,
	/* ButtonA,            */ KeyId::Space,
	/* ButtonB,            */ KeyId::LeftShift,
	/* TriggerL,           */ KeyId::E,
	/* TriggerZ,           */ KeyId::Tab,
	/* TriggerR,           */ KeyId::Numpad0,
	/* Start,              */ KeyId::Enter,
	/* ButtonX,            */ KeyId::X,
	/* ButtonY,            */ KeyId::C,
	/* SaveState,          */ KeyId::F2,
	/* LoadState,          */ KeyId::F4,
	/* PrevState,          */ KeyId::F6,
	/* NextState,          */ KeyId::F7,
	/* PrevCheat,          */ KeyId::INVALID,
	/* NextCheat,          */ KeyId::INVALID,
	/* ToggleCheat,        */ KeyId::INVALID,
	/* ToggleFps,          */ KeyId::F3,
	/* Pause,              */ KeyId::P,
	/* FrameAdvance,       */ KeyId::K,
	/* FastForward,        */ KeyId::RightBracket,
	/* ToggleFastForward,  */ KeyId::Backslash,
	/* SlowMotion,         */ KeyId::LeftBracket,
	/* ToggleSlowMotion,   */ KeyId::Quote,
	/* Rewind,             */ KeyId::Backspace,
	/* Quit,               */ KeyId::Escape,
	/* HardReset,          */ KeyId::Grave,
	/* ToggleFullscreen,   */ KeyId::F11,
	/* RetroMenu,          */ KeyId::F1,
	/* RecordVideo,        */ KeyId::NumpadAsterisk,
	/* RecordInputs,       */ KeyId::INVALID,
	/* Screenshot,         */ KeyId::F12,
	/* VolumeUp,           */ KeyId::NumpadPlus,
	/* VolumeDown,         */ KeyId::NumpadMinus,
	/* Mute                */ KeyId::Equals,
	/* GrabMouse           */ KeyId::F10
};
