mirror of
https://github.com/yuzu-mirror/yuzu.git
synced 2024-11-18 09:50:00 +00:00
android: Only do first startup automapping if nothing has been mapped
This commit is contained in:
parent
bdf8aca750
commit
a1c4f53c8c
1 changed files with 8 additions and 2 deletions
|
@ -80,8 +80,14 @@ class EmulationActivity : AppCompatActivity(), SensorEventListener {
|
||||||
super.onCreate(savedInstanceState)
|
super.onCreate(savedInstanceState)
|
||||||
|
|
||||||
InputHandler.updateControllerData()
|
InputHandler.updateControllerData()
|
||||||
val playerOne = NativeConfig.getInputSettings(true)[0]
|
val players = NativeConfig.getInputSettings(true)
|
||||||
if (!playerOne.hasMapping() && InputHandler.androidControllers.isNotEmpty()) {
|
var hasConfiguredControllers = false
|
||||||
|
players.forEach {
|
||||||
|
if (it.hasMapping()) {
|
||||||
|
hasConfiguredControllers = true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (!hasConfiguredControllers && InputHandler.androidControllers.isNotEmpty()) {
|
||||||
var params: ParamPackage? = null
|
var params: ParamPackage? = null
|
||||||
for (controller in InputHandler.registeredControllers) {
|
for (controller in InputHandler.registeredControllers) {
|
||||||
if (controller.get("port", -1) == 0) {
|
if (controller.get("port", -1) == 0) {
|
||||||
|
|
Loading…
Reference in a new issue