Comment 19 for bug 602877

Revision history for this message
In , Alexander Surkov (surkov-alexander) wrote :

(In reply to comment #15)

> Since the call to
> TakeFocus in SetSelectionRange doesn't work on non-tabbabe elements, I reasoned
> that the change belongs there.

I think TakeFocus() should work on focusable element, it shouldn't depend whether element is focusable or not.

> This patch works much better than the one where I forced the focus. The change
> is also localized to one function in nsHyperTextAccessible.cpp, rather than
> several files. Basically, rather than TakeFocus, I used MoveFocus with the
> nsIFocusManager::MOVEFOCUS_CARET flag as Neal suggested. I watched how
> MoveFocus gets called when I move with arrow keys, and I called it the same
> way. It relies on there being a selection, so rather than calling it before
> setting the selection where we use to call TakeFocus, I call MoveFocus after
> selection.

What's happen when caret navigation mode is off?

Bill, could you please work on mochitests as well? Btw, does a11y mochitests pass?