<?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>53783</bug_id>
          
          <creation_ts>2011-02-04 10:00:44 -0800</creation_ts>
          <short_desc>Dynamic changes to the lang attribute not seen by e.g. div:lang() selector</short_desc>
          <delta_ts>2012-08-17 00:13:15 -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>Layout and Rendering</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</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>
          <dependson>94092</dependson>
          <blocked>76364</blocked>
          <everconfirmed>0</everconfirmed>
          <reporter name="jag (Peter Annema)">jag-webkit</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>ap</cc>
    
    <cc>esprehn</cc>
    
    <cc>falken</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>345565</commentid>
    <comment_count>0</comment_count>
      <attachid>81239</attachid>
    <who name="jag (Peter Annema)">jag-webkit</who>
    <bug_when>2011-02-04 10:00:44 -0800</bug_when>
    <thetext>Created attachment 81239
Simple test case, courtesy of Boris Zbarsky

Dynamically setting the lang attribute doesn&apos;t trigger a style update for selectors that (now / no longer) match.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>695047</commentid>
    <comment_count>1</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2012-08-14 09:34:42 -0700</bug_when>
    <thetext>I think that this has need fixed already. Bug 76364 tracks adding tests.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>695871</commentid>
    <comment_count>2</comment_count>
    <who name="Matt Falkenhagen">falken</who>
    <bug_when>2012-08-15 02:51:14 -0700</bug_when>
    <thetext>Yes, this was fixed in the patch that added lang to -webkit-locale mapping, which also added a style recalc for when lang is set (http://trac.webkit.org/changeset/103608). In the current code, the style recalc occurs because lang is one of the attributes in HTMLElement::isPresentationAttribute.

Some tests for dynamic changes have landed as part of bug 76364, but technically they only test the mapping to -webkit-locale, and not the CSS :lang selector.

I think it&apos;d be good to add a new test specifically for the :lang selector. I&apos;ll upload a patch.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>697958</commentid>
    <comment_count>3</comment_count>
    <who name="Matt Falkenhagen">falken</who>
    <bug_when>2012-08-17 00:13:15 -0700</bug_when>
    <thetext>Closing bug as the test in bug 94092 landed.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="0"
              isprivate="0"
          >
            <attachid>81239</attachid>
            <date>2011-02-04 10:00:44 -0800</date>
            <delta_ts>2011-02-04 10:00:44 -0800</delta_ts>
            <desc>Simple test case, courtesy of Boris Zbarsky</desc>
            <filename>bug631352.html</filename>
            <type>text/html</type>
            <size>245</size>
            <attacher name="jag (Peter Annema)">jag-webkit</attacher>
            
              <data encoding="base64">PCFET0NUWVBFIGh0bWw+CjxodG1sPgogIDxoZWFkPgogICAgPHN0eWxlPgogICAgICBkaXY6bm90
KDpsYW5nKGZvbykpIHsgZGlzcGxheTogbm9uZTsgfQogICAgPC9zdHlsZT4KICA8L2hlYWQ+CiAg
PGJvZHkgb25sb2FkPSJkb2N1bWVudC5ib2R5Lm9mZnNldFdpZHRoOyBkb2N1bWVudC5ib2R5Lmxh
bmcgPSAnZm9vJyI+CiAgICA8ZGl2PlRoaXMgdGV4dCBzaG91bGQgYmUgdmlzaWJsZTwvZGl2Pgog
IDwvYm9keT4KPC9odG1sPgo=
</data>

          </attachment>
      

    </bug>

</bugzilla>