Closed Bug 358085 Opened 16 years ago Closed 16 years ago
nbsp in lists causes get
Child At Index to fail
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9a1) Gecko/20061025 Minefield/3.0a1 Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9a1) Gecko/20061025 Minefield/3.0a1 This one took a VERY LONG time to track down. If one embeds an in a list, it will cause the accessible hierarchy for the list to become corrupt - you can get what seems to be a valid child count, but getChildAtIndex will return None. Reproducible: Always Steps to Reproduce: 1. Open attached HTML content in Firefox. It might be illegal HTML, but it's a snippet from a test HTML document tossed at us by the Firefox team. 2. Run the attached test program. 3. Arrow up and down in the HTML content. You'll see the ERROR line(s). Actual Results: TRAVERSING +- ￼￼ <CORBA.Object 'IDL:Accessibility/Accessible:1.0' at 0x8234368> document fr ame 0 +- <CORBA.Object 'IDL:Accessibility/Accessible:1.0' at 0x8234200> list 0 ERROR getting child 0 from acc=list with 5 kids +- <CORBA.Object 'IDL:Accessibility/Accessible:1.0' at 0x8206558> list 1 +- • feeling listless. TYPE=CIRCLE <CORBA.Object 'IDL:Accessibility/Accessible :1.0' at 0x82341b0> list item 0 +- • blah, blah, blah (square) <CORBA.Object 'IDL:Accessibility/Accessible:1.0 ' at 0x8232ff0> list item 1 +- • whine, whine, whine(disc) <CORBA.Object 'IDL:Accessibility/Accessible:1.0 ' at 0x82341b0> list item 2 DONE TRAVERSING Goodbye. Expected Results: Something that says it has n kids should allow you to get them.
text node is not supposed to be exposed under Linux. so it will fail to get atk object at the index where text node is.
Assignee: nobody → Evan.Yan
Status: UNCONFIRMED → NEW
Ever confirmed: true
This one suffers from the same problem (the list says it has children, but there are none to be found) took a couple more hours to find - it's an odd construct where the list is used for what appears to be indentation purposes: <ul> <b>Table Header Cells spanning multiple rows:</b> <table> <tbody> <tr> <td>foo</td> </tr> </tbody> </table> </ul>
Evan found a general problem with lists that have text directly inside of them. We should have a fix soon.
make nsHTMLListAccessible inherit from nsHyperTextAccessible.
Attachment #243778 - Flags: review?(aaronleventhal)
And I'm tring to add assertion into nsAccessible::Init() to make sure something with a text child at least supports nsIAccessibleText. I'm looking at layout code to learn how to traversal DOMNode, cause accessible objects may not be cached when it init.
Attachment #243778 - Flags: review?(aaronleventhal) → review+
Checking in nsHTMLTextAccessible.h; /cvsroot/mozilla/accessible/src/html/nsHTMLTextAccessible.h,v <-- nsHTMLTextAccessible.h new revision: 1.41; previous revision: 1.40 done
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.