diff --git a/config.def.h b/config.def.h index 47a2994a9b..6c70b6e946 100644 --- a/config.def.h +++ b/config.def.h @@ -756,6 +756,8 @@ static const bool input_descriptor_hide_unbound = false; static const unsigned input_max_users = 5; +static const unsigned input_poll_type_behavior = 1; + #ifdef IOS static const bool ui_companion_start_on_boot = false; #else diff --git a/menu/intl/menu_hash_us.c b/menu/intl/menu_hash_us.c index 4e0e0aa898..a2795809c9 100644 --- a/menu/intl/menu_hash_us.c +++ b/menu/intl/menu_hash_us.c @@ -700,6 +700,8 @@ static const char *menu_hash_to_str_us_label(uint32_t hash) return "screen_resolution"; case MENU_LABEL_USE_BUILTIN_IMAGE_VIEWER: return "use_builtin_image_viewer"; + case MENU_LABEL_INPUT_POLL_TYPE_BEHAVIOR: + return "input_poll_type_behavior"; default: break; } @@ -1648,6 +1650,8 @@ const char *menu_hash_to_str_us(uint32_t hash) return "Enable"; case MENU_LABEL_VALUE_START_CORE: return "Start Core"; + case MENU_LABEL_VALUE_INPUT_POLL_TYPE_BEHAVIOR: + return "Poll Type Behavior"; default: break; } diff --git a/menu/menu_displaylist.c b/menu/menu_displaylist.c index 6c102a0944..34398947dc 100644 --- a/menu/menu_displaylist.c +++ b/menu/menu_displaylist.c @@ -1777,6 +1777,8 @@ static int menu_displaylist_parse_load_content_settings(menu_displaylist_info_t menu_hash_to_str(MENU_LABEL_VALUE_CORE_INPUT_REMAPPING_OPTIONS), menu_hash_to_str(MENU_LABEL_CORE_INPUT_REMAPPING_OPTIONS), MENU_SETTING_ACTION, 0, 0); + + menu_entries_push(info->list, menu_hash_to_str(MENU_LABEL_VALUE_CORE_CHEAT_OPTIONS), menu_hash_to_str(MENU_LABEL_CORE_CHEAT_OPTIONS), @@ -2678,6 +2680,8 @@ int menu_displaylist_push_list(menu_displaylist_info_t *info, unsigned type) ret = menu_displaylist_parse_settings(menu, info, menu_hash_to_str(MENU_LABEL_INPUT_SMALL_KEYBOARD_ENABLE), PARSE_ONLY_BOOL, false); #endif + ret = menu_displaylist_parse_settings(menu, info, + menu_hash_to_str(MENU_LABEL_INPUT_POLL_TYPE_BEHAVIOR), PARSE_ONLY_UINT, false); ret = menu_displaylist_parse_settings(menu, info, menu_hash_to_str(MENU_LABEL_INPUT_ICADE_ENABLE), PARSE_ONLY_BOOL, false); ret = menu_displaylist_parse_settings(menu, info, diff --git a/menu/menu_hash.h b/menu/menu_hash.h index fcbe35662a..7e8bf50d3e 100644 --- a/menu/menu_hash.h +++ b/menu/menu_hash.h @@ -22,6 +22,9 @@ extern "C" { #endif +#define MENU_LABEL_INPUT_POLL_TYPE_BEHAVIOR 0x8360107bU +#define MENU_LABEL_VALUE_INPUT_POLL_TYPE_BEHAVIOR 0xaa23fc1eU + #define MENU_LABEL_VALUE_SYSTEM_INFO_DYNAMIC_SUPPORT 0xe5f4b599U #define MENU_LABEL_UI_COMPANION_ENABLE 0xb2d7a20cU diff --git a/menu/menu_setting.c b/menu/menu_setting.c index fe85202415..051f65fa13 100644 --- a/menu/menu_setting.c +++ b/menu/menu_setting.c @@ -2791,6 +2791,9 @@ void general_write_handler(void *data) switch (hash) { + case MENU_LABEL_INPUT_POLL_TYPE_BEHAVIOR: + core.poll_type = *setting->value.integer; + break; case MENU_LABEL_VIDEO_SCALE_INTEGER: { video_viewport_t vp; @@ -5193,6 +5196,19 @@ static bool setting_append_list_input_options( general_read_handler); menu_settings_list_current_add_range(list, list_info, 1, MAX_USERS, 1, true, true); + CONFIG_UINT( + list, list_info, + &settings->input.poll_type_behavior, + menu_hash_to_str(MENU_LABEL_INPUT_POLL_TYPE_BEHAVIOR), + menu_hash_to_str(MENU_LABEL_VALUE_INPUT_POLL_TYPE_BEHAVIOR), + input_poll_type_behavior, + &group_info, + &subgroup_info, + parent_group, + general_write_handler, + general_read_handler); + menu_settings_list_current_add_range(list, list_info, 0, 2, 1, true, true); + #if TARGET_OS_IPHONE CONFIG_BOOL( list, list_info,