Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 369045 - [Text] Selection set with delay
Summary: [Text] Selection set with delay
Status: RESOLVED FIXED
Alias: None
Product: RAP
Classification: RT
Component: RWT (show other bugs)
Version: 1.5   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 1.5 M5   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-01-19 04:24 EST by Tim Buschtoens CLA
Modified: 2012-01-30 08:59 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tim Buschtoens CLA 2012-01-19 04:24:16 EST
Programatically setting a selection on Text delays for 50ms (TextUtil.js). While not much, it can could happen that a keypress cached by the browser gets executed before it's applied, which is then messing up selection and text content.
Comment 1 Tim Buschtoens CLA 2012-01-19 06:49:36 EST
Fixed CVS HEAD. Selection is set on appear.
Comment 2 Ivan Furnadjiev CLA 2012-01-29 04:30:51 EST
With this change the initial setting of selection does not work anymore in IE, Chrome and Safari. Reproducible with Controls Demo -> Text tab. Open the text tab in one of these browsers -> text is not selected. Works fine in Firefox and Opera.
Comment 3 Tim Buschtoens CLA 2012-01-30 08:59:57 EST
Also fixed.

For webkit, the problem seems to be when setting the same selection values twice. For IE, the issue was that setting the selection length on any text, even if it has length zero, resets all other selections to 0. Fixed in TextField.js and TextUtil.js