[webkit-dev] image maps to be focused via tab
browserwk at gmail.com
Mon Nov 17 22:55:51 PST 2008
Darin Adler 写道:
> On Nov 14, 2008, at 12:24 AM, browserwk wrote:
>> Before list, i assume html page have only one <img> and <map>(also one
>> <area>) tag, but also they are bounded.
>> In order to focus navigate via tab, i did follow things.
>> 1 to identify <img>,<area> tag
>> I can get the <img> or <area> node from
>> 2 get absolutely position
>> Also, i had got the position of the <img> and each <area> node with
>> nonstandard way, in any way.
>> If i use areaNode->renderer(), i will got NULL.
>> I didn't know the reason.If u can, tell me more.
>> 3 to focus <area> node
>> In this step, i fail to focus the <area> node, moreover didn't see the
>> focus ring.
>> And i found the <area> node never pass through the isKeyboardFocusable()
>> So, some questions
>> <1> I want to know the factor that a node need be focusable, just like
>> <area> node.
>> <2> Can i render the focus ring, when i got the <area> node and it's
>> absolutely postion ?
> This doesn't sound like the right approach. To make this work the
> approach would not to be write new code to navigate, but rather to
> change the existing code so that it will do this when necessary.
> Assuming the page has only one <img>, one <map>, and one <area> seems
> completely wrong, and I'm not sure it's helpful to designing a solution.
> The premises behind your questions <1> and <2> are wrong so I really
> don't see how I can answer the questions.
> Sorry, I'd love to help, but I'm stuck here.
> -- Darin
> webkit-dev mailing list
> webkit-dev at lists.webkit.org
Thanks all reply.
Hi, Darin Adler
May be my post confuse you.
First, i understand the particular img/area pair, add also read
The reasion why making such a assuming is that to simplify the problem.
In othe words, i have hold the <area> node and it's available in the
img. As for the img/area pair, i can solve it.
The <area> node can be got from Node::traverseNextNode() function.
But now, the area node didn't pass through the
Node::isKeyBoardFocusable() function, also not render the focus ring on
the <area> node.
yes, i want to let the <area> node be added to the FocusController
architecture just like other focusable node, such as <a> tag.
That's my wish.
I hope you understand.
More information about the webkit-dev