In the following simplified html example with two bold tag and two links, I would expect four uiElements represented thru accessibility. Instead, I see eight uiElements. Somehow WebKit is creating another AXStaticText that contains a space character as the AXValue after every bold or link tag. See the screenshot for an example of one of these spacer AXStaticText. Note that the start marker is the same as the end marker.
Created attachment 29855 [details]
Comment on attachment 29855 [details]
> + // text elements that are just empty whitespace should not be returned
> + String text = renderText->text()->simplifyWhiteSpace();
> + if (text.isNull() || text.isEmpty())
> + return true;
> + return false;
This should just be:
There's no need for a separate isNull check since null strings are also guaranteed to be empty. But really, to be efficient, it should be:
Unfortunately, that function is currently defined for StringImpl* but not for String. Since RenderText guarantees that text() will never return null (you can see assertions to that effect inside the class), you can do this:
I値l say review- because it would be better to do the more efficient version.
Created attachment 29856 [details]
Comment on attachment 29856 [details]
Same comments on this patch, but this also seems to include other seemingly-unrelated changes. Maybe fixing two bugs at once?
you're too quick for me. first time uploaded i forgot the DumpRenderTree changes
i obsoleted the first patch, then tried to upload again, but didn't see the comments until i had uploaded
Created attachment 29857 [details]
updated patch based on darin's review.
it seems that i can use
Comment on attachment 29857 [details]