[Android] Only dismiss the input dialog when an input is registered. Before it would dismiss upon the first event. Fixes a bug where control sticks wouldn't register because of the AlertDialog closing immediately after the "if (firstEvent)" branch.
This commit is contained in:
parent
ba274368f8
commit
e12c66b6cf
|
@ -156,17 +156,18 @@ public final class InputConfigFragment extends PreferenceFragment
|
||||||
String bindStr = "Device '" + InputConfigFragment.getInputDesc(input) + "'-Axis " + range.getAxis() + "-";
|
String bindStr = "Device '" + InputConfigFragment.getInputDesc(input) + "'-Axis " + range.getAxis() + "-";
|
||||||
NativeLibrary.SetConfig("Dolphin.ini", "Android", pref.getKey(), bindStr);
|
NativeLibrary.SetConfig("Dolphin.ini", "Android", pref.getKey(), bindStr);
|
||||||
pref.setSummary(bindStr);
|
pref.setSummary(bindStr);
|
||||||
|
dialog.dismiss();
|
||||||
}
|
}
|
||||||
else if (m_values.get(a) < (event.getAxisValue(range.getAxis()) - 0.5f))
|
else if (m_values.get(a) < (event.getAxisValue(range.getAxis()) - 0.5f))
|
||||||
{
|
{
|
||||||
String bindStr = "Device '" + InputConfigFragment.getInputDesc(input) + "'-Axis " + range.getAxis() + "+";
|
String bindStr = "Device '" + InputConfigFragment.getInputDesc(input) + "'-Axis " + range.getAxis() + "+";
|
||||||
NativeLibrary.SetConfig("Dolphin.ini", "Android", pref.getKey(), bindStr);
|
NativeLibrary.SetConfig("Dolphin.ini", "Android", pref.getKey(), bindStr);
|
||||||
pref.setSummary(bindStr);
|
pref.setSummary(bindStr);
|
||||||
|
dialog.dismiss();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
dialog.dismiss();
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue