GNOME Bugzilla – Bug 497218
No "object:active-descendant-changed" generated when arrowing into table in gtk-demo Tree View -> List Store demo.
Last modified: 2008-01-09 12:37:35 UTC
See also Orca bug #486895 which is affected by this problem. In particular, the evaluation in comment #2: http://bugzilla.gnome.org/show_bug.cgi?id=486895#c2 ---- Steps to reproduce: 0. Run Orca. 1. Run gtk-demo Tree View -> List Store demo. The demo comes up with the "Bug Number" column header with focus. 2. Arrow right twice to the "Description" column header. 3. Arrow down once. In Orca at this point, we get an "object:state-changed:focused" event for the table. OBJECT EVENT: object:state-changed:focused detail=(1,0) app.name='gtk-demo' name='None' role='table' state='enabled focusable focused sensitive showing visible manages descendants' relations='' The problem is that we have not had (not do we subsequently get) an "object:active-descendant-changed" event for the child in the table which has just been selected. We are unable to derive this information (which table cell is currently selected) from the information provided by just the "object:state-changed:focused" event.
Just ping'ing on this one. Li, any ideas?
Except the bug described, I also found there is no focus state for the focused cell except the first one. By searching the history, maybe this is a regression many years ago...
Created attachment 102310 [details] [review] proposed patch emit "active-descendant-changed" when focus come into the table body, and add focus state to the focused cell.
Created attachment 102331 [details] Orca debug.out generated whilst testing this problem. Patch NOT applied yet (i.e. the "before" case).
Created attachment 102332 [details] Orca debug.out generated whilst testing this problem. With patch applied. Commentary to follow.
Li, I could not get the second part of these diffs to correctly apply using patch against gail SVN HEAD (revision 1318). I was able to work out from the context diffs, where the patch should go (offset by quite a large chunk), so I applied it by hand. I believe it successfully applied and I was able to build/install gail. To be positive, it would be better if you could regenerate a new patch against latest SVN HEAD. Even then, I don't think it's doing the correct thing. There are no new "object:active-descendant-changed" events. Here's a more detailed analysis. I've attached two orca debug.out's: 1/ A test run without the patch being applied. 2/ A test run with the patch applied. The "without patch" case. ========================= From the first one (the "without patch" case), you will see we do the Down key event to move from the Description column header into the table at line 470. After that we get the following events: Line 480: ---------> QUEUEING EVENT object:state-changed:focused Line 483: vvvvv PROCESS OBJECT EVENT object:state-changed:focused vvvvv OBJECT EVENT: object:state-changed:focused detail=(0,0) app.name='gtk-demo' name='Description' role='table column header' state='enabled focusable focused selectable sensitive showing visible' relations='' Finding top-level object for source.name=Description Line 485: ---------> QUEUEING EVENT object:state-changed:focused Line 497: vvvvv PROCESS OBJECT EVENT object:state-changed:focused vvvvv OBJECT EVENT: object:state-changed:focused detail=(1,0) app.name='gtk-demo' name='None' role='table' state='enabled focusable focused sensitive showing visible manages descendants' relations='' This event causes SPEECH OUTPUT: 'Fixed? column header' to be spoken (see line 579) Other events queued for this key down are: Line 486: ---------> QUEUEING EVENT object:selection-changed Line 499: ---------> QUEUEING EVENT focus: The "with patch" case. ====================== For the second one (the "with patch" case), you will see we do the Down key event to move from the Description column header into the table at line 470. After that we get the following events: Line 480: ---------> QUEUEING EVENT object:state-changed:focused Line 483: vvvvv PROCESS OBJECT EVENT object:state-changed:focused vvvvv OBJECT EVENT: object:state-changed:focused detail=(0,0) app.name='gtk-demo' name='Description' role='table column header' state='enabled focusable focused selectable sensitive showing visible' relations='' Line 485: ---------> QUEUEING EVENT object:state-changed:focused Line 497: vvvvv PROCESS OBJECT EVENT object:state-changed:focused vvvvv OBJECT EVENT: object:state-changed:focused detail=(1,0) app.name='gtk-demo' name='None' role='table' state='enabled focusable focused sensitive showing visible manages descendants' relations='' This event again causes SPEECH OUTPUT: 'Fixed? column header' to be spoken (see line 579) Other events queued for this key down are: Line 486: ---------> QUEUEING EVENT object:selection-changed Line 511: ---------> QUEUEING EVENT focus: I do not see any new "object:active-descendant-changed" events.
Sorry, that should have been rev 1308 of gailtreeview.c (not 1318).
The patch was made against gtk+ SVN HEAD since gail has been moved to gtk+ HEAD (will not released with GNOME 2.22). I made a new patch with gail module and have tested with accerciser. No matter which patch is attached (the gtk+ one or the gail one), I can see "object:active-descendant-changed" emitted when press DOWN in "Description" column header, output attached. I only listened "object:state-changed" and "object:active-descendant-changed". BTW, I don't see object:state-changed:focused(1, 0, None) emitted from column header when press RIGHT, is this a bug bothers ORCA?
Created attachment 102363 [details] [review] patch based on gail
Created attachment 102364 [details] accerciser output
> The patch was made against gtk+ SVN HEAD since gail has been moved to gtk+ HEAD > (will not released with GNOME 2.22). Ah, I didn't realize. I'll check out latest gtk+ from SVN HEAD tomorrow and retry this. Any chance of running the steps to reproduce this problem with Orca debug turned on full, and attaching the debug.out to this bug report please? If not, I'll try that tomorrow. Steps to reproduce: 0. Run Orca. 1. Run gtk-demo Tree View -> List Store demo. The demo comes up with the "Bug Number" column header with focus. 2. Arrow right twice to the "Description" column header. 3. Arrow down once. Thanks.
Created attachment 102367 [details] output from orca In line 1897 I pressed Down. And line 2077 is the "object:active-descendant-changed" signal.
Please don't remove the gail.pc file installed by gail when you try gtk+ HEAD. gtk+ doesn't install gail.pc for now but at-spi and libgnomeui still depend on gail.
Thanks Li. This looks like it's now doing the correct thing and the patch can be checked in and the bug closed. Will, do you agree? It also looks like we have some work still to do with Orca to get it to do the right speaking. As it currently stands (with reference to your debug.out): It first processes an "object:state-changed:focused" event at line 1914: vvvvv PROCESS OBJECT EVENT object:state-changed:focused vvvvv OBJECT EVENT: object:state-changed:focused detail=(0,0) app.name='gtk-demo' name='Description' role='table column header' state='ENABLED FOCUSABLE FOCUSED SELECTABLE SENSITIVE SHOWING VISIBLE' relations='' Then an "object:state-changed:focused" event at line 1936: vvvvv PROCESS OBJECT EVENT object:state-changed:focused vvvvv OBJECT EVENT: object:state-changed:focused detail=(1,0) app.name='gtk-demo' name=None role='table' state='ENABLED FOCUSABLE FOCUSED SENSITIVE SHOWING VISIBLE MANAGES_DESCENDANTS' relations='' and from that speaks: SPEECH OUTPUT: 'Fixed? column header' at line 2064 It then processes an "object:selection-changed" event at line 2070: vvvvv PROCESS OBJECT EVENT object:selection-changed vvvvv OBJECT EVENT: object:selection-changed detail=(0,0) app.name='gtk-demo' name=None role='table' state='ENABLED FOCUSABLE FOCUSED SENSITIVE SHOWING VISIBLE MANAGES_DESCENDANTS' relations='' Then the new "object:active-descendant-changed" at line 2077: vvvvv PROCESS OBJECT EVENT object:active-descendant-changed vvvvv OBJECT EVENT: object:active-descendant-changed detail=(7,0) app.name='gtk-demo' name=None role='table' state='ENABLED FOCUSABLE FOCUSED SENSITIVE SHOWING VISIBLE MANAGES_DESCENDANTS' relations='' and from that speaks: SPEECH OUTPUT: 'Description column header' The problem really is that the first spoken line: SPEECH OUTPUT: 'Fixed? column header' is bogus. But that's because of the code in the onFocus() routine in default.py in Orca always just taking the first selected child. See comment #2 of bug #486895 http://bugzilla.gnome.org/show_bug.cgi?id=486895#c2 for a more detailed analysis of this. I'm not sure there is a simple fix for that. Unless we got the "object:active-descendant-changed" event before the "object:state-changed:focused" event...
(In reply to comment #14) > Thanks Li. This looks like it's now doing the correct thing and the > patch can be checked in and the bug closed. Will, do you agree? I agree -- keep in mind that the patch needs to go into two places (the old gail and the new GTK+) since the GAIL integration into GTK+ won't be officially released until after GNOME 2.22. See http://bugzilla.gnome.org/show_bug.cgi?id=169488#c28 of bug #169488 for information on that. > It also looks like we have some work still to do with Orca to > get it to do the right speaking. > ... > It first processes an "object:state-changed:focused" event at line 1914: ... > Then an "object:state-changed:focused" event at line 1936: ... > and from that speaks: > SPEECH OUTPUT: 'Fixed? column header' ... > It then processes an "object:selection-changed" event at line 2070: ... > Then the new "object:active-descendant-changed" at line 2077: ... > and from that speaks: > SPEECH OUTPUT: 'Description column header' ... > The problem really is that the first spoken line: > SPEECH OUTPUT: 'Fixed? column header' > is bogus. ... > I'm not sure there is a simple fix for that. Unless we got the > "object:active-descendant-changed" event before the > "object:state-changed:focused" event... I'm not sure, either. We could potentially make the object:active-descendant-changed event force a speech.stop() if it is going to end up presenting information.
Li, in trying to fixup Orca to correctly handle the new "object:active-descendant-changed" events, I discovered a new test case where we are still not getting an "object:active-descendant-changed" event. See Orca bug #486895 for more details, in particular comment 10: http://bugzilla.gnome.org/show_bug.cgi?id=486895#c10 Steps to reproduce: 1/ Start Orca. 2/ Start gtk-demo Tree View -> List Store demo. The demo comes up with the "Bug Number" column header with focus. 3/ Arrow right twice to the "Description" column header. 4/ Arrow down twice. 5/ Arrow left once. Focus is on the "Critical" text in the Severity column. 6/ Press Shift-Tab. Focus is given to the "Severity" column header. 7/ Arrow down once. Focus is back on the "Critical" text but Orca speaks: SPEECH OUTPUT: '' SPEECH OUTPUT: 'Fixed? column header' SPEECH OUTPUT: 'check box not checked ' But it's the same problem. No "object:selection-changed" event, so we are unable to setup the index of the child that can be used in onFocus(). So what you've done certainly helps very much, but it looks like there is another code path through gailtreeview.c that's going to need to send this event. Thanks.
Yes, the problem is we don't act when focus leave the table (shift-tab). So when focus comes in again, gail thinks it has been reported before and ignore it.
I filed a new bug for the problem (bug #508255). Patch is ready, will paste later. I need to have dinner first and do some merge work from gail to gtk+ :)
Created attachment 102456 [details] [review] final patch
I am going to close this bug and paste the patch to bug #508255.