Set focusOnClick property.
Whether the widget should grab focus when it is clicked with the mouse.
This property is only relevant for widgets that can take focus.
Set focusOnClick property.