fixed displaying extra setup options for wipe gestures only if selected
[rocksndiamonds.git] / src / screens.c
index d9814948d7e21dc0bf15325e316d5b97d65d9115..6ece1110727fd797d8743884607b9a33c298c6d7 100644 (file)
@@ -5426,6 +5426,16 @@ static struct TokenInfo setup_info_input[] =
 };
 
 static struct TokenInfo setup_info_touch[] =
+{
+  { TYPE_ENTER_LIST,   execSetupChooseTouchControls, "Touch Control Type:" },
+  { TYPE_STRING,       &touch_controls_text,   ""                      },
+  { TYPE_EMPTY,                NULL,                   ""                      },
+  { TYPE_LEAVE_MENU,   execSetupMain,          "Back"                  },
+
+  { 0,                 NULL,                   NULL                    }
+};
+
+static struct TokenInfo setup_info_touch_wipe_gestures[] =
 {
   { TYPE_ENTER_LIST,   execSetupChooseTouchControls, "Touch Control Type:" },
   { TYPE_STRING,       &touch_controls_text,   ""                      },
@@ -5825,6 +5835,9 @@ static void DrawSetupScreen_Generic()
   {
     setup_info = setup_info_touch;
     title_string = "Setup Touch Ctrls";
+
+    if (strEqual(setup.touch.control_type, TOUCH_CONTROL_WIPE_GESTURES))
+      setup_info = setup_info_touch_wipe_gestures;
   }
   else if (setup_mode == SETUP_MODE_SHORTCUTS)
   {