My jQM app doesn't have input device such as mouse or tap sensor, only arrow keys. So the buttons should first show the active/hover state programmatically, then user can hit enter to confirm the click, where click
event is triggered.
I've tried
$('#radio' + radioIndex).trigger('hover');
and
$('#radio' + radioIndex).trigger('mouseenter');
which didn't work. Do I have to refresh button? How?
From Chrome Developer Tools I can see that what I want is actually pseudo style :hover
or :active
. But it doesn't look there is an easy way to toggle them without messing up with jQM CSS.
How can I properly set the button state from the code to active/hover, thus imitating mouse hovering on it?