Forum Discussion
NB_
5 years agoRoku Guru
m.Button.setFocus(true)
...
m.top.SetFocus(true)first you set the focus on the button, then on the parent.
The input focus can be "focused" on only one widget at a time - the last one on which setFocus(true) was called - in this case it is the "parent" component. Commenting out `m.top.SetFocus(true)` should fix it?
chaklasiyanikun
5 years agoRoku Guru
NB_ Thank you for your reply, I don't know this is a better way or not. I solved this issue using Create one separate Component and set by default focus like below and use in the main scene in init().
<Component id = "MyComponentName" extends = "Group" initialFocus = "Button"> ..... ..... </Component>