mirror of
https://github.com/skyline-emu/skyline.git
synced 2024-12-27 16:45:30 +03:00
OSC: delegate config reset to individual buttons
This commit is contained in:
parent
3fc09f0953
commit
2794af6d06
@ -184,4 +184,9 @@ abstract class OnScreenButton(
|
|||||||
relativeX = defaultRelativeX
|
relativeX = defaultRelativeX
|
||||||
relativeY = defaultRelativeY
|
relativeY = defaultRelativeY
|
||||||
}
|
}
|
||||||
|
|
||||||
|
open fun resetConfig() {
|
||||||
|
resetRelativeValues()
|
||||||
|
config.enabled = true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -269,8 +269,7 @@ class OnScreenControllerView @JvmOverloads constructor(context : Context, attrs
|
|||||||
|
|
||||||
fun resetControls() {
|
fun resetControls() {
|
||||||
controls.allButtons.forEach {
|
controls.allButtons.forEach {
|
||||||
it.resetRelativeValues()
|
it.resetConfig()
|
||||||
it.config.enabled = true
|
|
||||||
}
|
}
|
||||||
controls.globalScale = 1.15f
|
controls.globalScale = 1.15f
|
||||||
controls.alpha = 155
|
controls.alpha = 155
|
||||||
|
Loading…
Reference in New Issue
Block a user