New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 734006 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner: ----
Closed: Jun 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 2
Type: Bug-Regression



Sign in to add a comment

Range object has the same startOffset and endOffset for a selection in a iframe

Reported by tmor...@odilotid.es, Jun 16 2017

Issue description

Steps to reproduce the problem:
I've develop a simple web page which test the bug.

1. Unzip and deploy in a simple http server
2. Open the page using the last Chrome Mobile
3. Select some text from the iframe
4. Touch the selected text.
5. Open the browser console and check that the Range object has the same value for startOffset and endOffset properties

What is the expected behavior?
The value of startOffset and endOffset must be different and to correspond to the position of the selection.

If you test on Chrome 52 works fine.

What went wrong?
The Range object from the selection has the same value for startOffset and endOffset properties.

Did this work before? Yes Chrome 52

Chrome version: 58.0.3029.110  Channel: stable
OS Version: all
Flash Version: 

This bug ONLY happen in Mobile version, in Desktop works fine
 
testPage.zip
1.2 KB Download
Cc: aelias@chromium.org
Components: Blink>Editing>Selection

Comment 2 by aelias@chromium.org, Jun 20 2017

Cc: tkent@chromium.org yosin@chromium.org

Comment 3 by yosin@chromium.org, Jun 20 2017

Status: WontFix (was: Unconfirmed)
This is expected behavior, Chrome, Edge and Firefox set collapsed selection at tap/click.

Note: IFRAME doesn't affect this behavior.

Comment 4 by tmor...@odilotid.es, Jun 20 2017

I've attached two screen shots one executed on Chrome Mobile 52 and the other one on Chrome Mobile 58

You can see that the text selected inside the iframe is empty in version 58 but is not empty in version 52.

This issue only happen on Android devices not in Desktop.


Chrome_Mobile_52.png
131 KB View Download
Chrome_Mobile_58.png
111 KB View Download

Comment 5 by tkent@chromium.org, Jun 27 2017

 Issue 737038  has been merged into this issue.

Comment 6 by tkent@chromium.org, Jun 27 2017

Does listening 'mouseup' event make sense on Android?
Does it work well if you listen 'selectionchange' event?

Comment 7 by tmor...@odilotid.es, Jun 28 2017

mouseup event works fine on all Android and iOS devices, the problem is when I call Range.toString() function that returns an empty string because startOffset and endOffset have the same values.

Sign in to add a comment