Bug 1077345 part.10 nsTextStore should use NS_COMPOSITION_COMMIT event r=emk
authorMasayuki Nakano <masayuki@d-toybox.com>
Tue, 25 Nov 2014 14:02:33 +0900
changeset 241637 c6ba52ccca3566aed0dddbedd5bd30f0fbc9bb83
parent 241636 fd6fb9dc0e093e6ff0b3acc7632f00e656b318ec
child 241638 d47301e9d1522e64dff2f08fc32d0ce35ed11c51
push id4311
push userraliiev@mozilla.com
push dateMon, 12 Jan 2015 19:37:41 +0000
treeherdermozilla-beta@150c9fed433b [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersemk
bugs1077345
milestone36.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1077345 part.10 nsTextStore should use NS_COMPOSITION_COMMIT event r=emk
widget/windows/nsTextStore.cpp
--- a/widget/windows/nsTextStore.cpp
+++ b/widget/windows/nsTextStore.cpp
@@ -1669,34 +1669,22 @@ nsTextStore::FlushPendingActions()
                 "flushing COMPOSITION_END={ mData=\"%s\" }",
                 this, NS_ConvertUTF16toUTF8(action.mData).get()));
 
         action.mData.ReplaceSubstring(NS_LITERAL_STRING("\r\n"),
                                       NS_LITERAL_STRING("\n"));
 
         PR_LOG(sTextStoreLog, PR_LOG_DEBUG,
                ("TSF: 0x%p   nsTextStore::FlushPendingActions(), "
-                "dispatching compositionchange event...", this));
-        WidgetCompositionEvent compositionChange(true, NS_COMPOSITION_CHANGE,
+                "dispatching compositioncommit event...", this));
+        WidgetCompositionEvent compositionCommit(true, NS_COMPOSITION_COMMIT,
                                                  mWidget);
-        mWidget->InitEvent(compositionChange);
-        compositionChange.mData = action.mData;
-        mWidget->DispatchWindowEvent(&compositionChange);
-        if (!mWidget || mWidget->Destroyed()) {
-          break;
-        }
-
-        PR_LOG(sTextStoreLog, PR_LOG_DEBUG,
-               ("TSF: 0x%p   nsTextStore::FlushPendingActions(), "
-                "dispatching compositionend event...", this));
-        WidgetCompositionEvent compositionEnd(true, NS_COMPOSITION_END,
-                                              mWidget);
-        compositionEnd.mData = compositionChange.mData;
-        mWidget->InitEvent(compositionEnd);
-        mWidget->DispatchWindowEvent(&compositionEnd);
+        mWidget->InitEvent(compositionCommit);
+        compositionCommit.mData = action.mData;
+        mWidget->DispatchWindowEvent(&compositionCommit);
         if (!mWidget || mWidget->Destroyed()) {
           break;
         }
         break;
       }
       case PendingAction::SELECTION_SET: {
         PR_LOG(sTextStoreLog, PR_LOG_DEBUG,
                ("TSF: 0x%p   nsTextStore::FlushPendingActions() "