mirror of
https://github.com/skyline-emu/skyline.git
synced 2024-12-25 23:25:28 +03:00
Ignore OSC roll-over events if the button is already pressed
This commit is contained in:
parent
560fcd9442
commit
655ca8f89b
@ -151,7 +151,11 @@ class OnScreenControllerView @JvmOverloads constructor(context : Context, attrs
|
||||
for (buttonPair in controls.buttonPairs) {
|
||||
if (buttonPair.contains(button)) {
|
||||
for (otherButton in buttonPair) {
|
||||
if (otherButton != button && otherButton.config.enabled && otherButton.isTouched(event.getX(fingerId), event.getY(fingerId))) {
|
||||
if (otherButton.partnerPointerId == -1 &&
|
||||
otherButton != button &&
|
||||
otherButton.config.enabled &&
|
||||
otherButton.isTouched(event.getX(fingerId), event.getY(fingerId))
|
||||
) {
|
||||
otherButton.partnerPointerId = fingerId
|
||||
if (otherButton.onFingerDown(x, y))
|
||||
onButtonStateChangedListener?.invoke(otherButton.buttonId, ButtonState.Pressed)
|
||||
|
Loading…
Reference in New Issue
Block a user