I'm working on the Webview's Voiceover, and the problem is that when the page changes, the VoiceOver's Focus needs to go to the top, but the Focus always moves near where the previous page had Focus.
Attempting to force focus with element.focus () doesn't work.
Searched out
$ (window) .load (function () {
function setVoiceOverFocus () {
var focusInterval = 10; // ms, time between function calls
var focusTotalRepetitions = 10; // number of repetitions
$ ("btn_page_back"). setAttribute ('tabindex', '0');
$ ("btn_page_back"). blur ();
var focusRepetitions = 0;
var interval = window.setInterval (function () {
$ ("btn_page_back"). focus ();
focusRepetitions ++;
if (focusRepetitions> = focusTotalRepetitions) {
window.clearInterval (interval);
}
}, focusInterval);
}
})
The code doesn't work either.
Is there a way to control the focus of Voiceover in JavaScript or to send focus to the top?