Title: [121271] trunk/Source/WebCore
Revision
121271
Author
j...@apple.com
Date
2012-06-26 11:38:56 -0700 (Tue, 26 Jun 2012)

Log Message

On Mac, autocorrection sometimes fails to take place in Safari.
https://bugs.webkit.org/show_bug.cgi?id=89982

Reviewed by Darin Adler.

Existing test was turned off due to intermittent failure, which is caused by autocorrection result depending on user data
that may be altered by previous test runs. Hopefully we can turn the test back on once we have a way to make autocorrection
behave consistently.

Basically we should check the value of shouldCheckForCorrection, not shouldShowCorrectionPanel, to determine if we should
early return in markAndReplaceFor().

* editing/Editor.cpp:
(WebCore::Editor::markAndReplaceFor):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (121270 => 121271)


--- trunk/Source/WebCore/ChangeLog	2012-06-26 18:34:54 UTC (rev 121270)
+++ trunk/Source/WebCore/ChangeLog	2012-06-26 18:38:56 UTC (rev 121271)
@@ -1,3 +1,20 @@
+2012-06-26  Jia Pu  <j...@apple.com>
+
+        On Mac, autocorrection sometimes fails to take place in Safari.
+        https://bugs.webkit.org/show_bug.cgi?id=89982
+
+        Reviewed by Darin Adler.
+
+        Existing test was turned off due to intermittent failure, which is caused by autocorrection result depending on user data
+        that may be altered by previous test runs. Hopefully we can turn the test back on once we have a way to make autocorrection
+        behave consistently.
+
+        Basically we should check the value of shouldCheckForCorrection, not shouldShowCorrectionPanel, to determine if we should
+        early return in markAndReplaceFor(). 
+
+        * editing/Editor.cpp:
+        (WebCore::Editor::markAndReplaceFor):
+
 2012-06-26  Joe Thomas  <joetho...@motorola.com>
 
         Do early-return when author and user styles are disabled.

Modified: trunk/Source/WebCore/editing/Editor.cpp (121270 => 121271)


--- trunk/Source/WebCore/editing/Editor.cpp	2012-06-26 18:34:54 UTC (rev 121270)
+++ trunk/Source/WebCore/editing/Editor.cpp	2012-06-26 18:38:56 UTC (rev 121271)
@@ -2085,7 +2085,7 @@
             if (result->type == TextCheckingTypeLink && selectionOffset > resultLocation + resultLength + 1)
                 continue;
 
-            if (!(shouldPerformReplacement || shouldShowCorrectionPanel || shouldMarkLink) || !doReplacement)
+            if (!(shouldPerformReplacement || shouldCheckForCorrection || shouldMarkLink) || !doReplacement)
                 continue;
 
             String replacedString = plainText(rangeToReplace.get());
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to