mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-01-26 15:55:31 +01:00
Android: Allow changing controller settings during emulation
This commit is contained in:
parent
c2779aef06
commit
32cb41007b
@ -50,6 +50,12 @@ public class InputDeviceSetting extends StringSingleChoiceSetting
|
|||||||
mValues = devices;
|
mValues = devices;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isEditable()
|
||||||
|
{
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean canClear()
|
public boolean canClear()
|
||||||
{
|
{
|
||||||
|
@ -48,6 +48,12 @@ public final class InputMappingControlSetting extends SettingsItem
|
|||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isEditable()
|
||||||
|
{
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
public EmulatedController getController()
|
public EmulatedController getController()
|
||||||
{
|
{
|
||||||
return mController;
|
return mController;
|
||||||
|
@ -293,13 +293,10 @@ public final class SettingsFragmentPresenter
|
|||||||
sl.add(new SubmenuSetting(mContext, R.string.config, MenuTag.CONFIG));
|
sl.add(new SubmenuSetting(mContext, R.string.config, MenuTag.CONFIG));
|
||||||
sl.add(new SubmenuSetting(mContext, R.string.graphics_settings, MenuTag.GRAPHICS));
|
sl.add(new SubmenuSetting(mContext, R.string.graphics_settings, MenuTag.GRAPHICS));
|
||||||
|
|
||||||
if (!NativeLibrary.IsRunning())
|
sl.add(new SubmenuSetting(mContext, R.string.gcpad_settings, MenuTag.GCPAD_TYPE));
|
||||||
|
if (mSettings.isWii())
|
||||||
{
|
{
|
||||||
sl.add(new SubmenuSetting(mContext, R.string.gcpad_settings, MenuTag.GCPAD_TYPE));
|
sl.add(new SubmenuSetting(mContext, R.string.wiimote_settings, MenuTag.WIIMOTE));
|
||||||
if (mSettings.isWii())
|
|
||||||
{
|
|
||||||
sl.add(new SubmenuSetting(mContext, R.string.wiimote_settings, MenuTag.WIIMOTE));
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
sl.add(new HeaderSetting(mContext, R.string.setting_clear_info, 0));
|
sl.add(new HeaderSetting(mContext, R.string.setting_clear_info, 0));
|
||||||
|
@ -133,6 +133,10 @@ public final class EmulationFragment extends Fragment implements SurfaceHolder.C
|
|||||||
public void onResume()
|
public void onResume()
|
||||||
{
|
{
|
||||||
super.onResume();
|
super.onResume();
|
||||||
|
|
||||||
|
if (mInputOverlay != null && NativeLibrary.IsGameMetadataValid())
|
||||||
|
mInputOverlay.refreshControls();
|
||||||
|
|
||||||
run(activity.isActivityRecreated());
|
run(activity.isActivityRecreated());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -131,10 +131,6 @@ public final class InputOverlay extends SurfaceView implements OnTouchListener
|
|||||||
if (!mPreferences.getBoolean("OverlayInitV3", false))
|
if (!mPreferences.getBoolean("OverlayInitV3", false))
|
||||||
defaultOverlay();
|
defaultOverlay();
|
||||||
|
|
||||||
// Load the controls if we can. If not, EmulationActivity has to do it later.
|
|
||||||
if (NativeLibrary.IsGameMetadataValid())
|
|
||||||
refreshControls();
|
|
||||||
|
|
||||||
// Set the on touch listener.
|
// Set the on touch listener.
|
||||||
setOnTouchListener(this);
|
setOnTouchListener(this);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user