Android: Optimization and layout improvements
Android: Add missing spacing to input mod layout Android: Account for awkward select button icon
This commit is contained in:
parent
dae71628a5
commit
eb9d455338
|
@ -358,19 +358,18 @@ public class GL2JNIActivity extends Activity {
|
|||
} else {
|
||||
GL2JNIView.lt[playerNum] = (int) (L2 * 255);
|
||||
GL2JNIView.rt[playerNum] = (int) (R2 * 255);
|
||||
|
||||
if (prefs.getInt(Gamepad.pref_js_rstick + pad.portId[playerNum], 0) == 2) {
|
||||
if (RS_Y > 0.25) {
|
||||
handle_key(playerNum, pad.map[playerNum][0]/* A */, true);
|
||||
pad.wasKeyStick[playerNum] = true;
|
||||
} else if (RS_Y < 0.25) {
|
||||
handle_key(playerNum, pad.map[playerNum][1]/* B */, true);
|
||||
pad.wasKeyStick[playerNum] = true;
|
||||
} else if (pad.wasKeyStick[playerNum]) {
|
||||
handle_key(playerNum, pad.map[playerNum][0], false);
|
||||
handle_key(playerNum, pad.map[playerNum][1], false);
|
||||
pad.wasKeyStick[playerNum] = false;
|
||||
}
|
||||
}
|
||||
if (prefs.getInt(Gamepad.pref_js_rstick + pad.portId[playerNum], 0) == 2) {
|
||||
if (RS_Y > 0.25) {
|
||||
handle_key(playerNum, pad.map[playerNum][0]/* A */, true);
|
||||
pad.wasKeyStick[playerNum] = true;
|
||||
} else if (RS_Y < 0.25) {
|
||||
handle_key(playerNum, pad.map[playerNum][1]/* B */, true);
|
||||
pad.wasKeyStick[playerNum] = true;
|
||||
} else if (pad.wasKeyStick[playerNum]) {
|
||||
handle_key(playerNum, pad.map[playerNum][0], false);
|
||||
handle_key(playerNum, pad.map[playerNum][1], false);
|
||||
pad.wasKeyStick[playerNum] = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -358,19 +358,18 @@ public class GL2JNINative extends NativeActivity {
|
|||
} else {
|
||||
GL2JNIView.lt[playerNum] = (int) (L2 * 255);
|
||||
GL2JNIView.rt[playerNum] = (int) (R2 * 255);
|
||||
|
||||
if (prefs.getInt(Gamepad.pref_js_rstick + pad.portId[playerNum], 0) == 2) {
|
||||
if (RS_Y > 0.25) {
|
||||
handle_key(playerNum, pad.map[playerNum][0]/* A */, true);
|
||||
pad.wasKeyStick[playerNum] = true;
|
||||
} else if (RS_Y < 0.25) {
|
||||
handle_key(playerNum, pad.map[playerNum][1]/* B */, true);
|
||||
pad.wasKeyStick[playerNum] = true;
|
||||
} else if (pad.wasKeyStick[playerNum]) {
|
||||
handle_key(playerNum, pad.map[playerNum][0], false);
|
||||
handle_key(playerNum, pad.map[playerNum][1], false);
|
||||
pad.wasKeyStick[playerNum] = false;
|
||||
}
|
||||
}
|
||||
if (prefs.getInt(Gamepad.pref_js_rstick + pad.portId[playerNum], 0) == 2) {
|
||||
if (RS_Y > 0.25) {
|
||||
handle_key(playerNum, pad.map[playerNum][0]/* A */, true);
|
||||
pad.wasKeyStick[playerNum] = true;
|
||||
} else if (RS_Y < 0.25) {
|
||||
handle_key(playerNum, pad.map[playerNum][1]/* B */, true);
|
||||
pad.wasKeyStick[playerNum] = true;
|
||||
} else if (pad.wasKeyStick[playerNum]) {
|
||||
handle_key(playerNum, pad.map[playerNum][0], false);
|
||||
handle_key(playerNum, pad.map[playerNum][1], false);
|
||||
pad.wasKeyStick[playerNum] = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:ems="10"
|
||||
android:layout_marginLeft="4dp"
|
||||
android:text="@string/customize_touch_controls" />
|
||||
|
||||
<LinearLayout
|
||||
|
@ -50,6 +51,7 @@
|
|||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.5"
|
||||
android:ems="10"
|
||||
android:layout_marginLeft="4dp"
|
||||
android:gravity="center_vertical|left"
|
||||
android:text="@string/touch_vibration" />
|
||||
|
||||
|
@ -85,6 +87,7 @@
|
|||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:layout_marginLeft="4dp"
|
||||
android:text="@string/vibration_duration" />
|
||||
|
||||
<LinearLayout
|
||||
|
@ -130,6 +133,7 @@
|
|||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:ems="10"
|
||||
android:layout_marginLeft="4dp"
|
||||
android:text="@string/customize_physical_controls" />
|
||||
|
||||
<LinearLayout
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -22,6 +22,7 @@
|
|||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:ems="10"
|
||||
android:layout_marginLeft="4dp"
|
||||
android:text="@string/customize_touch_controls" />
|
||||
|
||||
<LinearLayout
|
||||
|
@ -50,6 +51,7 @@
|
|||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.5"
|
||||
android:ems="10"
|
||||
android:layout_marginLeft="4dp"
|
||||
android:gravity="center_vertical|left"
|
||||
android:text="@string/touch_vibration" />
|
||||
|
||||
|
@ -85,6 +87,7 @@
|
|||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:layout_marginLeft="4dp"
|
||||
android:text="@string/vibration_duration" />
|
||||
|
||||
<LinearLayout
|
||||
|
@ -130,6 +133,7 @@
|
|||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:ems="10"
|
||||
android:layout_marginLeft="4dp"
|
||||
android:text="@string/customize_physical_controls" />
|
||||
|
||||
<LinearLayout
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -99,6 +99,12 @@
|
|||
<string name="enable_microphone">Enable Microphone(s)</string>
|
||||
<string name="controller_1_vmu">Includes 2 VMUs (or 1 VMU / 1 Mic)</string>
|
||||
|
||||
<string name="a_button">A Button</string>
|
||||
<string name="b_button">B Button</string>
|
||||
<string name="x_button">X Button</string>
|
||||
<string name="y_button">Y Button</string>
|
||||
<string name="right_button">R Button</string>
|
||||
<string name="left_button">L Button</string>
|
||||
<string name="dpad_up">D-Pad Up</string>
|
||||
<string name="dpad_down">D-Pad Down</string>
|
||||
<string name="dpad_left">D-Pad Left</string>
|
||||
|
|
Loading…
Reference in New Issue