Bug 323995 - [Accessibility] StyledText selection incorrect after caret moved event
Summary: [Accessibility] StyledText selection incorrect after caret moved event
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 3.6.1   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.6.1   Edit
Assignee: Felipe Heidrich CLA
QA Contact: Carolyn MacLeod CLA
URL:
Whiteboard:
Keywords: accessibility
Depends on:
Blocks:
 
Reported: 2010-08-30 12:38 EDT by Carolyn MacLeod CLA
Modified: 2010-08-31 02:22 EDT (History)
3 users (show)

See Also:
john.arthorne: pmc_approved+
Silenio_Quarti: review+


Attachments
Patch from Felipe (2.29 KB, patch)
2010-08-30 12:40 EDT, Carolyn MacLeod CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Carolyn MacLeod CLA 2010-08-30 12:38:24 EDT
Eclipse 3.6.1 RC2.

One of the JAWS developers sent me an email saying IAccessibleText::selection in StyledText was incorrect after he received a "caret moved" event.

It turns out that this is because JAWS runs in-process, and StyledText does indeed send "caret moved" before finalizing the selection.

When testing with AccProbe running out-of-process, this discrepancy went unnoticed, because the selection is finalized before an out-of-process client can ask for it.
Comment 1 Carolyn MacLeod CLA 2010-08-30 12:40:35 EDT
Created attachment 177750 [details]
Patch from Felipe
Comment 2 Carolyn MacLeod CLA 2010-08-30 12:47:29 EDT
I discovered how to test Felipe's patch with AccProbe. The Event Monitor view allows getting in-context events. I tested with using shift+arrow key to change selection (which was the exact problem that the JAWS developer reported), as well as various combinations of arrow keys with or without shift, shift+HOME/END, as well as shift+mouse click.

The selection is now correctly reported in all cases that I tested.
Are there any other cases I should test for?
Comment 3 Carolyn MacLeod CLA 2010-08-30 12:50:01 EDT
SSQ, can you please review the patch for possible inclusion in 3.6.1?
I looked at the code, and it seems ok to me, however I do not know if it covers all cases, and I do not know if I tested all cases.

If it looks good to you as well, then I would like to bring it forward to the PMC for inclusion in 3.6.1.
Comment 4 John Arthorne CLA 2010-08-30 14:01:22 EDT
+1. I reviewed the patch with Silenio and Car. I witnessed the bug occurring before the fix (incorrect selection reported by in-process screen reader), and that the selection is correct when the fix is applied. We also tested corner cases such as the caret changing but the selection staying unchanged.
Comment 5 Carolyn MacLeod CLA 2010-08-30 14:06:59 EDT
Fixed > 20100830 in 3.6.1 stream and in HEAD.
Comment 6 Dani Megert CLA 2010-08-31 01:59:25 EDT
>+1. I reviewed the patch with Silenio and Car.
John, please update the pmc_approved flag if you approve a bug as PMC for RC3 and beyond. Thanks.
Comment 7 Dani Megert CLA 2010-08-31 02:00:18 EDT
>>+1. I reviewed the patch with Silenio and Car.
>John, please update the pmc_approved flag if you approve a bug as PMC for RC3
>and beyond. Thanks.
Oops! It was actually there. Not sure why I didn't see it. Sorry for the spam.