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

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>18931</bug_id>
          
          <creation_ts>2012-09-20 09:17:36 +0000</creation_ts>
          <short_desc>D3E should define when compositionupdate event is fired</short_desc>
          <delta_ts>2013-08-26 16:29:01 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebAppsWG</product>
          <component>HISTORICAL - DOM3 Events</component>
          <version>unspecified</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>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Masayuki Nakano">masayuki</reporter>
          <assigned_to name="Travis Leithead [MSFT]">travil</assigned_to>
          <cc>garykac</cc>
    
    <cc>kochi</cc>
    
    <cc>mike</cc>
    
    <cc>www-dom</cc>
          
          <qa_contact>public-webapps-bugzilla</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>74124</commentid>
    <comment_count>0</comment_count>
    <who name="Masayuki Nakano">masayuki</who>
    <bug_when>2012-09-20 09:17:36 +0000</bug_when>
    <thetext>I forgot to file this issue here.

I mentioned this in the ML but nobody never replied this:
http://lists.w3.org/Archives/Public/www-dom/2012JanMar/0239.html

&gt; I think D3E spec should define the timing of compositionupdate event clearly.
&gt; 
&gt; On IE9, compositionupdate event is fired *after* editor content is modified actually.
&gt; 
&gt; On WebKit and Gecko, it&apos;s fired *before* editor content is modified.
&gt; 
&gt; That means there is a difference. That is, whether web app can access modified content by value of &lt;input&gt; or &lt;textarea&gt;, or innerHTML of editing host of a contenteditable element.
&gt; 
&gt; I think that most web application developers expect IE9&apos;s behavior because compositionupdate isn&apos;t cancelable and they may want to access the modified value.
&gt; 
&gt; For the compatibility between browsers, I&apos;d like to suggest that D3E should define the timing. I recommend the IE9&apos;s behavior.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>91184</commentid>
    <comment_count>1</comment_count>
    <who name="Takayoshi Kochi">kochi</who>
    <bug_when>2013-07-24 00:26:58 +0000</bug_when>
    <thetext>Here are relevant bugs filed for WebKit and Chromium:
(though they are talking about &apos;compositionend&apos; event)
https://bugs.webkit.org/show_bug.cgi?id=31902
https://code.google.com/p/chromium/issues/detail?id=41945</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>91185</commentid>
    <comment_count>2</comment_count>
    <who name="Travis Leithead [MSFT]">travil</who>
    <bug_when>2013-07-24 00:37:03 +0000</bug_when>
    <thetext>Proposed spec text (replaces existing paragraph after the event definition):

A user agent SHOULD dispatch this event during a composition session when a text composition system updates its active text passage with a new character, which is reflected in the string in CompositionEvent.data. In text composition systems which keep the ongoing composition in sync with the input control, the compositionupdate event SHOULD be dispatched after the control is updated. Some text composition systems might not expose this information to the DOM, in which case this event will not fire during the composition process. If the composition session is canceled, this event will be fired immediately before the compositionend event, and the CompositionEvent.data attribute will be set to the empty string.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>91212</commentid>
    <comment_count>3</comment_count>
    <who name="Masayuki Nakano">masayuki</who>
    <bug_when>2013-07-24 07:14:43 +0000</bug_when>
    <thetext>If we will define &quot;input&quot; event, we need to define the order with &quot;input&quot; event too (not so important, though).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>91272</commentid>
    <comment_count>4</comment_count>
    <who name="Takayoshi Kochi">kochi</who>
    <bug_when>2013-07-25 09:24:34 +0000</bug_when>
    <thetext>Also for compositionend event?

ORIGINAL
==============
A user agent must dispatch this event when a text composition system completes or cancels the current composition session.

This event is dispatched immediately after the text composition system completes the composition session (e.g., the IME is closed, minimized, switched out of focus, or otherwise dismissed, and the focus switched back to the user agent).
==============

NEW
==============
A user agent must dispatch this event when a text composition system completes or cancels the current composition session, and the compositionend event SHOULD be
dispatched after the control is updated.

This event is dispatched immediately after the text composition system completes the composition session (e.g., the IME is closed, minimized, switched out of focus, or otherwise dismissed, and the focus switched back to the user agent). 
==============</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>