Merge pull request #537 from LoungeKatt/master
Onscreen menu fixes and reduction
|
@ -1 +1 @@
|
|||
014daafa2ab7a821beaf6041c68c50f8baf60b83
|
||||
0dba81b99abcf909937d6473bb7e5fc83bf33e6d
|
Before Width: | Height: | Size: 20 KiB After Width: | Height: | Size: 139 KiB |
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 10 KiB |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 7.0 KiB |
Before Width: | Height: | Size: 3.1 KiB After Width: | Height: | Size: 14 KiB |
Before Width: | Height: | Size: 7.0 KiB After Width: | Height: | Size: 138 KiB |
Before Width: | Height: | Size: 4.7 KiB After Width: | Height: | Size: 21 KiB |
Before Width: | Height: | Size: 27 KiB After Width: | Height: | Size: 26 KiB |
After Width: | Height: | Size: 13 KiB |
Before Width: | Height: | Size: 14 KiB After Width: | Height: | Size: 27 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 20 KiB |
|
@ -190,6 +190,7 @@ public class OnScreenMenu {
|
|||
|
||||
public class ConfigPopup extends PopupWindow {
|
||||
|
||||
private View rsticksetting;
|
||||
private View fullscreen;
|
||||
private View framelimit;
|
||||
private View audiosetting;
|
||||
|
@ -216,6 +217,29 @@ public class OnScreenMenu {
|
|||
});
|
||||
hlay.addView(up, configParams);
|
||||
menuItems.add(up);
|
||||
|
||||
rsticksetting = addbut(R.drawable.toggle_a_b, "Right Stick",
|
||||
new OnClickListener() {
|
||||
public void onClick(View v) {
|
||||
if (prefs
|
||||
.getBoolean(Gamepad.pref_js_rbuttons, true)) {
|
||||
prefs.edit()
|
||||
.putBoolean(Gamepad.pref_js_rbuttons,
|
||||
false).commit();
|
||||
modbut(rsticksetting, R.drawable.toggle_a_b);
|
||||
} else {
|
||||
prefs.edit()
|
||||
.putBoolean(Gamepad.pref_js_rbuttons,
|
||||
true).commit();
|
||||
modbut(rsticksetting, R.drawable.toggle_r_l);
|
||||
}
|
||||
dismiss();
|
||||
}
|
||||
});
|
||||
if (prefs.getBoolean(Gamepad.pref_js_rbuttons, true)) {
|
||||
modbut(rsticksetting, R.drawable.toggle_r_l);
|
||||
}
|
||||
hlay.addView(rsticksetting, params);
|
||||
|
||||
fullscreen = addbut(R.drawable.widescreen, "Widescreen", new OnClickListener() {
|
||||
public void onClick(View v) {
|
||||
|
@ -498,8 +522,6 @@ public class OnScreenMenu {
|
|||
|
||||
public class MainPopup extends PopupWindow {
|
||||
|
||||
private View rsticksetting;
|
||||
|
||||
public MainPopup(Context c) {
|
||||
super(c);
|
||||
setBackgroundDrawable(null);
|
||||
|
@ -525,7 +547,7 @@ public class OnScreenMenu {
|
|||
}
|
||||
}), params);
|
||||
|
||||
hlay.addView(addbut(R.drawable.vmu_swap, "Disk Swap", new OnClickListener() {
|
||||
hlay.addView(addbut(R.drawable.disk_swap, "Disk Swap", new OnClickListener() {
|
||||
public void onClick(View v) {
|
||||
JNIdc.diskSwap(null);
|
||||
dismiss();
|
||||
|
@ -539,29 +561,6 @@ public class OnScreenMenu {
|
|||
}
|
||||
}), params);
|
||||
|
||||
rsticksetting = addbut(R.drawable.toggle_a_b, "Right Stick",
|
||||
new OnClickListener() {
|
||||
public void onClick(View v) {
|
||||
if (prefs
|
||||
.getBoolean(Gamepad.pref_js_rbuttons, true)) {
|
||||
prefs.edit()
|
||||
.putBoolean(Gamepad.pref_js_rbuttons,
|
||||
false).commit();
|
||||
modbut(rsticksetting, R.drawable.toggle_a_b);
|
||||
} else {
|
||||
prefs.edit()
|
||||
.putBoolean(Gamepad.pref_js_rbuttons,
|
||||
true).commit();
|
||||
modbut(rsticksetting, R.drawable.toggle_r_l);
|
||||
}
|
||||
dismiss();
|
||||
}
|
||||
});
|
||||
if (prefs.getBoolean(Gamepad.pref_js_rbuttons, true)) {
|
||||
modbut(rsticksetting, R.drawable.toggle_r_l);
|
||||
}
|
||||
hlay.addView(rsticksetting, params);
|
||||
|
||||
hlay.addView(addbut(R.drawable.config, "Options", new OnClickListener() {
|
||||
public void onClick(View v) {
|
||||
displayConfigPopup(MainPopup.this);
|
||||
|
|