Android buttons: Inset 'rare controls', inset and resize 'gear icon' (#7792)
[oweals/minetest.git] / src / gui / touchscreengui.h
index d3ce8492949860663f9a7217e7429922958bdf1c..5102f188bf913578599d838018e2ac71c05d7ff3 100644 (file)
@@ -37,6 +37,7 @@ typedef enum {
        jump_id = 0,
        crunch_id,
        zoom_id,
+       special1_id,
        after_last_element_id,
        settings_starter_id,
        rare_controls_starter_id,
@@ -60,7 +61,13 @@ typedef enum {
        joystick_center_id
 } touch_gui_button_id;
 
-typedef enum { j_forward = 0, j_backward, j_left, j_right } touch_gui_joystick_move_id;
+typedef enum {
+       j_forward = 0,
+       j_backward,
+       j_left,
+       j_right,
+       j_special1
+} touch_gui_joystick_move_id;
 
 typedef enum {
        AHBB_Dir_Top_Bottom,
@@ -206,9 +213,9 @@ private:
        double m_camera_pitch = 0.0;
 
        // forward, backward, left, right
-       touch_gui_button_id m_joystick_names[4] = {
-                       forward_id, backward_id, left_id, right_id};
-       bool m_joystick_status[4] = {false, false, false, false};
+       touch_gui_button_id m_joystick_names[5] = {
+                       forward_id, backward_id, left_id, right_id, special1_id};
+       bool m_joystick_status[5] = {false, false, false, false, false};
 
        /*!
         * A line starting at the camera and pointing towards the
@@ -227,6 +234,7 @@ private:
        int m_joystick_id = -1;
        bool m_joystick_has_really_moved = false;
        bool m_fixed_joystick = false;
+       bool m_joystick_triggers_special1 = false;
        button_info *m_joystick_btn_off = nullptr;
        button_info *m_joystick_btn_bg = nullptr;
        button_info *m_joystick_btn_center = nullptr;