<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>8116</bug_id>
          
          <creation_ts>2006-03-31 21:01:55 -0800</creation_ts>
          <short_desc>REGRESSION: Selection issues occur when dragging from left to right in native text fields</short_desc>
          <delta_ts>2006-04-07 20:39:55 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>Forms</component>
          <version>420+</version>
          <rep_platform>Mac</rep_platform>
          <op_sys>OS X 10.4</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar, Regression</keywords>
          <priority>P1</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Chris Petersen">c.petersen87</reporter>
          <assigned_to name="Darin Adler">darin</assigned_to>
          <cc>adele</cc>
    
    <cc>hyatt</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>38136</commentid>
    <comment_count>0</comment_count>
    <who name="Chris Petersen">c.petersen87</who>
    <bug_when>2006-03-31 21:01:55 -0800</bug_when>
    <thetext>I&apos;m noticing when dragging left to right the selection while become invalid when I-beam cursor outside of the text field.

Steps to reproduce:

1) With TOT Webkit, open attached test case &quot;input_selection_test.html&quot;.
2) Place caret before &quot;T&quot; in &quot;This&quot;.
3) Mouse down and drag over &quot;This is a test&quot;. Move cursor outside the right edge of text field.
4) Notice the selection becomes invalid as you drag outside of text field
5) Again place caret before &quot;T&quot; in &quot;This&quot;.
6) Drag over &quot;This is a&quot; then move cursor to the bottom of text first
7) Move cursor outside of the text field and again selection becomes invalid

Note: If I place caret at the END of the text field and drag a selection ( from right to left), the selection remains intact if I move the cursor outside of field.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>38137</commentid>
    <comment_count>1</comment_count>
      <attachid>7430</attachid>
    <who name="Chris Petersen">c.petersen87</who>
    <bug_when>2006-03-31 21:09:43 -0800</bug_when>
    <thetext>Created attachment 7430
Sample input field</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>38139</commentid>
    <comment_count>2</comment_count>
    <who name="Chris Petersen">c.petersen87</who>
    <bug_when>2006-03-31 21:20:05 -0800</bug_when>
    <thetext>This issue is covered in &lt;rdar://problem/4499022&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>38140</commentid>
    <comment_count>3</comment_count>
    <who name="Chris Petersen">c.petersen87</who>
    <bug_when>2006-03-31 21:21:35 -0800</bug_when>
    <thetext>My original description should have said:

I&apos;m noticing when dragging left to right, the selection will become invalid
when I-beam cursor moves outside of the text field.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>38317</commentid>
    <comment_count>4</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2006-04-02 19:56:22 -0700</bug_when>
    <thetext>Bug 8134 describes almost exactly the same thing.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>38358</commentid>
    <comment_count>5</comment_count>
    <who name="Maciej Stachowiak">mjs</who>
    <bug_when>2006-04-02 23:25:43 -0700</bug_when>
    <thetext>These are all text field regressions so they should all be P1.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>38684</commentid>
    <comment_count>6</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2006-04-06 00:57:55 -0700</bug_when>
    <thetext>I&apos;ll take a look at these.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>38690</commentid>
    <comment_count>7</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2006-04-06 08:53:48 -0700</bug_when>
    <thetext>Something&apos;s going wrong in Selection::adjustForEditableContent, which is supposed to handle things like this.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>38692</commentid>
    <comment_count>8</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2006-04-06 09:06:42 -0700</bug_when>
    <thetext>The main problem seems to be the call to Range::compareBoundaryPoints inside Selection::validate. This won&apos;t handle selection endpoints that are inside the shadow DOM. That&apos;s what we need to fix.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>38693</commentid>
    <comment_count>9</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2006-04-06 09:14:21 -0700</bug_when>
    <thetext>I need to talk to Adele and Hyatt about this one. It&apos;s a side effect of the shadow DOM not having a parent that points to the real DOM. I understand why the real DOM can&apos;t point down into the shadow DOM, but I don&apos;t understand why it&apos;s a problem to have the shadow DOM pointing back up to the real one. To fix this, I&apos;m having to change tons of places to call shadowParentNode after calling parentNode, and I think that might not be the right way to go.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>38773</commentid>
    <comment_count>10</comment_count>
    <who name="Darin Adler">darin</who>
    <bug_when>2006-04-07 20:39:55 -0700</bug_when>
    <thetext>Turns out my fix for bug 8134 does fix the test case attached here.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="0"
              isprivate="0"
          >
            <attachid>7430</attachid>
            <date>2006-03-31 21:09:43 -0800</date>
            <delta_ts>2006-03-31 21:09:43 -0800</delta_ts>
            <desc>Sample input field</desc>
            <filename>input_selection_test.html</filename>
            <type>text/html</type>
            <size>155</size>
            <attacher name="Chris Petersen">c.petersen87</attacher>
            
              <data encoding="base64">PGh0bWw+CjxoZWFkPgo8dGl0bGU+ClRleHQgaW5wdXQgc2VsZWN0aW9uIHRlc3QKPC90aXRsZT4K
PC9oZWFkPgo8Ym9keT4KPGlucHV0IHR5cGU9InRleHQiIHNpemU9IjEwIiBzZWxlY3RlZCB2YWx1
ZT0iVGhpcyBpcyBhIHRlc3QiPjxicj4KCgo8L2JvZHk+CjwvaHRtbD4=
</data>

          </attachment>
      

    </bug>

</bugzilla>