add validation check for group.optionsAvailable
fixes crash when pressing back during initial video buffering
This commit is contained in:
parent
2c3a7b1f33
commit
07bc24b51a
|
@ -11,7 +11,7 @@ function onKeyEvent(key as string, press as boolean) as boolean
|
|||
return true
|
||||
else if key = "options"
|
||||
group = m.global.sceneManager.callFunc("getActiveScene")
|
||||
if group <> invalid and group.optionsAvailable
|
||||
if group <> invalid and group.optionsAvailable <> invalid and group.optionsAvailable
|
||||
group.lastFocus = group.focusedChild
|
||||
panel = group.findNode("options")
|
||||
panel.visible = true
|
||||
|
|
Loading…
Reference in New Issue
Block a user