<?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>135077</bug_id>
          
          <creation_ts>2014-07-18 16:04:35 -0700</creation_ts>
          <short_desc>_WKActivatedElementInfo.title should fallback to innerText if the link doesn&apos;t have title attribute.</short_desc>
          <delta_ts>2014-07-18 18:32:13 -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>WebKit2</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Yongjun Zhang">yongjun_zhang</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>andersca</cc>
    
    <cc>ap</cc>
    
    <cc>commit-queue</cc>
    
    <cc>mitz</cc>
    
    <cc>sam</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1023379</commentid>
    <comment_count>0</comment_count>
    <who name="Yongjun Zhang">yongjun_zhang</who>
    <bug_when>2014-07-18 16:04:35 -0700</bug_when>
    <thetext>Often, a link might not have title attribute.  In that case, we should use the link element&apos;s innerText as a fallback.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1023382</commentid>
    <comment_count>1</comment_count>
    <who name="Yongjun Zhang">yongjun_zhang</who>
    <bug_when>2014-07-18 16:06:12 -0700</bug_when>
    <thetext>&lt;rdar://17373799&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1023383</commentid>
    <comment_count>2</comment_count>
      <attachid>235155</attachid>
    <who name="Yongjun Zhang">yongjun_zhang</who>
    <bug_when>2014-07-18 16:12:38 -0700</bug_when>
    <thetext>Created attachment 235155
Fallback to link element&apos;s innerHTML if its title attribute is empty.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1023384</commentid>
    <comment_count>3</comment_count>
    <who name="Yongjun Zhang">yongjun_zhang</who>
    <bug_when>2014-07-18 16:13:56 -0700</bug_when>
    <thetext>(In reply to comment #2)
&gt; Created an attachment (id=235155) [details]
&gt; Fallback to link element&apos;s innerHTML if its title attribute is empty.
typo, it should be innerText.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1023390</commentid>
    <comment_count>4</comment_count>
      <attachid>235155</attachid>
    <who name="">mitz</who>
    <bug_when>2014-07-18 16:41:16 -0700</bug_when>
    <thetext>Comment on attachment 235155
Fallback to link element&apos;s innerHTML if its title attribute is empty.

View in context: https://bugs.webkit.org/attachment.cgi?id=235155&amp;action=review

&gt; Source/WebKit2/ChangeLog:6
&gt; +        When populate InteractionInformationAtPosition&apos;s title value, use a link element&apos;s innerText if it

typo: populate-&gt;populating</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1023400</commentid>
    <comment_count>5</comment_count>
      <attachid>235155</attachid>
    <who name="WebKit Commit Bot">commit-queue</who>
    <bug_when>2014-07-18 17:22:19 -0700</bug_when>
    <thetext>Comment on attachment 235155
Fallback to link element&apos;s innerHTML if its title attribute is empty.

Clearing flags on attachment: 235155

Committed r171253: &lt;http://trac.webkit.org/changeset/171253&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1023401</commentid>
    <comment_count>6</comment_count>
    <who name="WebKit Commit Bot">commit-queue</who>
    <bug_when>2014-07-18 17:22:22 -0700</bug_when>
    <thetext>All reviewed patches have been landed.  Closing bug.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1023420</commentid>
    <comment_count>7</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2014-07-18 18:27:45 -0700</bug_when>
    <thetext>Isn&apos;t this kind of business logic something that should be in the client? WebKit&apos;s job is to provide all the necessary information, not to lie about what the title is.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1023421</commentid>
    <comment_count>8</comment_count>
    <who name="">mitz</who>
    <bug_when>2014-07-18 18:32:13 -0700</bug_when>
    <thetext>(In reply to comment #7)
&gt; Isn&apos;t this kind of business logic something that should be in the client? WebKit&apos;s job is to provide all the necessary information, not to lie about what the title is.

WebKit uses the title internally for its built-in Add to Reading List action. I do think we’ll need to review _WKActivatedElementInfo’s properties and their names if we make it a public class.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>235155</attachid>
            <date>2014-07-18 16:12:38 -0700</date>
            <delta_ts>2014-07-18 17:22:19 -0700</delta_ts>
            <desc>Fallback to link element&apos;s innerHTML if its title attribute is empty.</desc>
            <filename>title_link.patch</filename>
            <type>text/plain</type>
            <size>1696</size>
            <attacher name="Yongjun Zhang">yongjun_zhang</attacher>
            
              <data encoding="base64">SW5kZXg6IFNvdXJjZS9XZWJLaXQyL0NoYW5nZUxvZwo9PT09PT09PT09PT09PT09PT09PT09PT09
PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09Ci0tLSBTb3VyY2UvV2Vi
S2l0Mi9DaGFuZ2VMb2cJKHJldmlzaW9uIDE3MTI0OCkKKysrIFNvdXJjZS9XZWJLaXQyL0NoYW5n
ZUxvZwkod29ya2luZyBjb3B5KQpAQCAtMSwzICsxLDE2IEBACisyMDE0LTA3LTE4ICBZb25nanVu
IFpoYW5nICA8eW9uZ2p1bl96aGFuZ0BhcHBsZS5jb20+CisKKyAgICAgICAgX1dLQWN0aXZhdGVk
RWxlbWVudEluZm8udGl0bGUgc2hvdWxkIGZhbGxiYW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g2NCw4IEBAIHZvaWQgV2ViUGFn
ZTo6Z2V0UG9zaXRpb25JbmZvcm1hdGlvbihjb24KICAgICAgICAgICAgIGlmIChsaW5rRWxlbWVu
dCkKICAgICAgICAgICAgICAgICBpbmZvLnVybCA9IFsoTlNVUkwgKilsaW5rRWxlbWVudC0+ZG9j
dW1lbnQoKS5jb21wbGV0ZVVSTChzdHJpcExlYWRpbmdBbmRUcmFpbGluZ0hUTUxTcGFjZXMobGlu
a0VsZW1lbnQtPmdldEF0dHJpYnV0ZShIVE1MTmFtZXM6OmhyZWZBdHRyKSkpIGFic29sdXRlU3Ry
aW5nXTsKICAgICAgICAgICAgIGluZm8udGl0bGUgPSBlbGVtZW50LT5mYXN0R2V0QXR0cmlidXRl
KEhUTUxOYW1lczo6dGl0bGVBdHRyKS5zdHJpbmcoKTsKKyAgICAgICAgICAgIGlmIChsaW5rRWxl
bWVudCAmJiBpbmZvLnRpdGxlLmlzRW1wdHkoKSkKKyAgICAgICAgICAgICAgICBpbmZvLnRpdGxl
ID0gZWxlbWVudC0+aW5uZXJUZXh0KCk7CiAgICAgICAgICAgICBpZiAoZWxlbWVudC0+cmVuZGVy
ZXIoKSkKICAgICAgICAgICAgICAgICBpbmZvLmJvdW5kcyA9IGVsZW1lbnQtPnJlbmRlcmVyKCkt
PmFic29sdXRlQm91bmRpbmdCb3hSZWN0KHRydWUpOwogICAgICAgICB9Cg==
</data>

          </attachment>
      

    </bug>

</bugzilla>