[webkit-dev] Focus traversal question

Artem Ananiev Artem.Ananiev at Sun.COM
Thu Nov 1 07:23:47 PDT 2007

After some search I found two methods in ChromeClient related to the question: 
canTakeFocus() and takeFocus(). Still, I see some problems with the reverse 
traversal (I tried text field on www.yahoo.com: when I press Shift+TAB, the 
methods from ChromeClient are not called).



Artem Ananiev wrote:
> To embed an instance of WebKit component into the application, it should 
> be a good 'citizen' of focus traversal chain. For instance, when focus 
> is in the component previous to WebKit and user presses TAB key, focus 
> should be moved to the first focusable component on the WebKit page; 
> while focus is on the last focusable component on the page and TAB is 
> pressed, focus should be traversed out of WebKit.
> Sometimes, for example, when I press mouse on any text field on the 
> page, WebKit requests focus from the platform (Widget::setFocus() 
> method). But I don't see any platform callbacks when focus should be 
> traversed out of WebKit. One more question is about first and last 
> focusable components on the page, how can I find them? It is required to 
> implement both forward and reverse traversal chains.
> Thanks,
> Artem
> _______________________________________________
> webkit-dev mailing list
> webkit-dev at lists.webkit.org
> http://lists.webkit.org/mailman/listinfo/webkit-dev

More information about the webkit-dev mailing list