Mercurial > repos > blastem
comparison nuklear_ui/blastem_nuklear.c @ 1664:cc5107def372
Fix binding UI for "6 button right" style controllers
author | Mike Pavone <pavone@retrodev.com> |
---|---|
date | Sun, 30 Dec 2018 23:21:59 -0800 |
parents | c3c3b65f17aa |
children | a1e0ed70ad82 |
comparison
equal
deleted
inserted
replaced
1663:f00fec236d56 | 1664:cc5107def372 |
---|---|
1054 | 1054 |
1055 binding_box(context, bindings, "Right Shoulder", bind_box_left, font->height/2, bind_box_width, | 1055 binding_box(context, bindings, "Right Shoulder", bind_box_left, font->height/2, bind_box_width, |
1056 selected_controller_info.variant == VARIANT_6B_BUMPERS ? 1 : 2, | 1056 selected_controller_info.variant == VARIANT_6B_BUMPERS ? 1 : 2, |
1057 (int[]){ | 1057 (int[]){ |
1058 selected_controller_info.variant == VARIANT_6B_RIGHT ? SDL_CONTROLLER_BUTTON_LEFTSHOULDER : SDL_CONTROLLER_BUTTON_RIGHTSHOULDER, | 1058 selected_controller_info.variant == VARIANT_6B_RIGHT ? SDL_CONTROLLER_BUTTON_LEFTSHOULDER : SDL_CONTROLLER_BUTTON_RIGHTSHOULDER, |
1059 selected_controller_info.variant == VARIANT_6B_RIGHT ? SDL_CONTROLLER_BUTTON_RIGHTSHOULDER : AXIS | SDL_CONTROLLER_AXIS_TRIGGERRIGHT | 1059 AXIS | SDL_CONTROLLER_AXIS_TRIGGERLEFT |
1060 }); | 1060 }); |
1061 | 1061 |
1062 binding_box(context, bindings, "Misc Buttons", (render_width() - bind_box_width) / 2, font->height/2, bind_box_width, 3, (int[]){ | 1062 binding_box(context, bindings, "Misc Buttons", (render_width() - bind_box_width) / 2, font->height/2, bind_box_width, 3, (int[]){ |
1063 SDL_CONTROLLER_BUTTON_BACK, | 1063 SDL_CONTROLLER_BUTTON_BACK, |
1064 SDL_CONTROLLER_BUTTON_GUIDE, | 1064 SDL_CONTROLLER_BUTTON_GUIDE, |
1096 | 1096 |
1097 binding_box(context, bindings, "Left Shoulder", bind_box_left, font->height/2, bind_box_width, | 1097 binding_box(context, bindings, "Left Shoulder", bind_box_left, font->height/2, bind_box_width, |
1098 selected_controller_info.variant == VARIANT_6B_BUMPERS ? 1 : 2, | 1098 selected_controller_info.variant == VARIANT_6B_BUMPERS ? 1 : 2, |
1099 (int[]){ | 1099 (int[]){ |
1100 selected_controller_info.variant == VARIANT_6B_RIGHT ? SDL_CONTROLLER_BUTTON_LEFTSTICK : SDL_CONTROLLER_BUTTON_LEFTSHOULDER, | 1100 selected_controller_info.variant == VARIANT_6B_RIGHT ? SDL_CONTROLLER_BUTTON_LEFTSTICK : SDL_CONTROLLER_BUTTON_LEFTSHOULDER, |
1101 selected_controller_info.variant == VARIANT_6B_RIGHT ? SDL_CONTROLLER_BUTTON_RIGHTSTICK : AXIS | SDL_CONTROLLER_AXIS_TRIGGERLEFT | 1101 SDL_CONTROLLER_BUTTON_RIGHTSTICK |
1102 }); | 1102 }); |
1103 | 1103 |
1104 binding_box(context, bindings, "D-pad", dpad_left, dpad_top, bind_box_width, 4, (int[]){ | 1104 binding_box(context, bindings, "D-pad", dpad_left, dpad_top, bind_box_width, 4, (int[]){ |
1105 SDL_CONTROLLER_BUTTON_DPAD_UP, | 1105 SDL_CONTROLLER_BUTTON_DPAD_UP, |
1106 SDL_CONTROLLER_BUTTON_DPAD_DOWN, | 1106 SDL_CONTROLLER_BUTTON_DPAD_DOWN, |