<html>
    <head>
      <base href="https://bugs.webkit.org/" />
    </head>
    <body><span class="vcard"><a class="email" href="mailto:rniwa&#64;webkit.org" title="Ryosuke Niwa &lt;rniwa&#64;webkit.org&gt;"> <span class="fn">Ryosuke Niwa</span></a>
</span> changed
              <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - AX: WKContentView needs to implement UITextInput methods to make speak selection highlighting work"
   href="https://bugs.webkit.org/show_bug.cgi?id=166955">bug 166955</a>
        <br>
             <table border="1" cellspacing="0" cellpadding="8">
          <tr>
            <th>What</th>
            <th>Removed</th>
            <th>Added</th>
          </tr>

         <tr>
           <td style="text-align:right;">Attachment #300064 Flags</td>
           <td>review?
           </td>
           <td>review+
           </td>
         </tr></table>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - AX: WKContentView needs to implement UITextInput methods to make speak selection highlighting work"
   href="https://bugs.webkit.org/show_bug.cgi?id=166955#c30">Comment # 30</a>
              on <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - AX: WKContentView needs to implement UITextInput methods to make speak selection highlighting work"
   href="https://bugs.webkit.org/show_bug.cgi?id=166955">bug 166955</a>
              from <span class="vcard"><a class="email" href="mailto:rniwa&#64;webkit.org" title="Ryosuke Niwa &lt;rniwa&#64;webkit.org&gt;"> <span class="fn">Ryosuke Niwa</span></a>
</span></b>
        <pre>Comment on <span class=""><a href="attachment.cgi?id=300064&amp;action=diff" name="attach_300064" title="patch">attachment 300064</a> <a href="attachment.cgi?id=300064&amp;action=edit" title="patch">[details]</a></span>
patch

View in context: <a href="https://bugs.webkit.org/attachment.cgi?id=300064&amp;action=review">https://bugs.webkit.org/attachment.cgi?id=300064&amp;action=review</a>

r=me assuming enrica &amp; darin are happy with this patch as well.

<span class="quote">&gt; Source/WebCore/editing/TextIterator.cpp:2675
&gt; +            if (matches(lastCharacterInBufferOffset - matchStartOffset, newMatchLength))</span >

We should probably call this &quot;match&quot; since we usually use a verb for function names.

<span class="quote">&gt; Source/WebCore/editing/TextIterator.cpp:2681
&gt; -Ref&lt;Range&gt; findPlainText(const Range&amp; range, const String&amp; target, FindOptions options)
&gt; +static void updateSearchBuffer(SearchBuffer&amp; buffer, const Range&amp; range)</span >

I think it's cleaner if updateSearchBuffer and findIteratorOptions were just merged into findPlainTextMatches
since findClosestPlainText and findPlainText don't need to have access to SearchBuffer at all.
So make findPlainTextMatches take a Range, and options before the adjustment.

<span class="quote">&gt; Source/WebCore/editing/TextIterator.cpp:2702
&gt; +static Ref&lt;Range&gt; rangeMatches(const Range&amp; range, TextIteratorBehavior iteratorOptions, size_t matchStart, size_t matchLength, bool searchForward)</span >

We don't have &quot;matches&quot;. We have a single match here.
So it's probably more appropriate to call this function rangeForMatch or matchedRange.

<span class="quote">&gt; Source/WebKit2/WebProcess/WebPage/ios/WebPageIOS.mm:1837
&gt; +        send(Messages::WebPageProxy::SelectionRectsCallback(Vector&lt;WebCore::SelectionRect&gt;(), callbackID));</span >

You couldn't just do ({ }, callbackID))?

<span class="quote">&gt; Source/WebKit2/WebProcess/WebPage/ios/WebPageIOS.mm:1846
&gt; +        send(Messages::WebPageProxy::SelectionRectsCallback(Vector&lt;WebCore::SelectionRect&gt;(), callbackID));</span >

Ditto.</pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>