GNOME Bugzilla – Bug 350854
Orca should handle object:state-changed:focus events
Last modified: 2008-07-01 15:06:36 UTC
Sometimes an object will only emit object:state-changed:focus events, even though it should also emit focus: events. An example of this is GEdit's edit area under GNOME 2.15: when one uses the metacity window menu to maximize/unmaximize a window, the edit area will only issue a object:state-changed:focus event. Orca should attempt to handle this and do the appropriate thing.
Created attachment 70698 [details] [review] Patch to set locus of focus on object:state-changed:focus events This patch does two things: 1) When it detects caret moved events for focused text areas that are not the locus of focus, it sets the locus of focus to the text area. This is somewhat passive fix and is also what we do in onText{Inserted,Deleted}. 2) When it detects an object:state-changed:focused event with a positive detail1, it sets the locus of focus to the event source. This is potentially a risky change since it applies to all object:state-changed:focused events. If this is shown to cause problems, we can remove this logic, but keep the logic in #1.
Fixed in the development version. The fix will be available in the next major release (0.2.9). Thank you for your bug report.
Reopening the bug. The fix caused StarOffice/OpenOffice to double speak lines in Writer. See bug #353268 for more details.
Created attachment 71803 [details] [review] Rework of the patch to move the required code into the gedit script.
New changes checked into CVS HEAD. Closing as FIXED.
That last line of the diff should of course be: default.Script.onStateChanged(self, event) Adjustment committed to CVS HEAD. Thanks Will.