[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

commit-queue at webkit.org commit-queue at webkit.org
Wed Dec 22 14:51:43 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit 51fdb21318159db4d317cc0e2b2582ff30452e8c
Author: commit-queue at webkit.org <commit-queue at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Fri Oct 22 16:11:40 2010 +0000

    2010-10-22  Jia Pu  <jpu at apple.com>
    
            Reviewed by Dan Bernstein.
    
            Regression (r69548): cancelled autocorrection suggestion is still applied.
            https://bugs.webkit.org/show_bug.cgi?id=48081
            <rdar://problem/8579765>
    
            The test requires a 0.3 second delay using setTimeout(). So we put it in manual-tests.
    
            * editing/Editor.cpp:
            (WebCore::Editor::handleRejectedCorrection): Clear autocorrection info when user dismissed the panel.
            * manual-tests/autocorrection/autocorrection-cancelled-by-ESC.html: Added.
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@70310 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 8bbcd3b..0178f04 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,17 @@
+2010-10-22  Jia Pu  <jpu at apple.com>
+
+        Reviewed by Dan Bernstein.
+
+        Regression (r69548): cancelled autocorrection suggestion is still applied.
+        https://bugs.webkit.org/show_bug.cgi?id=48081
+        <rdar://problem/8579765>
+        
+        The test requires a 0.3 second delay using setTimeout(). So we put it in manual-tests.
+
+        * editing/Editor.cpp:
+        (WebCore::Editor::handleRejectedCorrection): Clear autocorrection info when user dismissed the panel.
+        * manual-tests/autocorrection/autocorrection-cancelled-by-ESC.html: Added.
+
 2010-10-22  Andreas Kling  <kling at webkit.org>
 
         Reviewed by Kenneth Rohde Christiansen.
diff --git a/WebCore/editing/Editor.cpp b/WebCore/editing/Editor.cpp
index 7b3d055..4d6d258 100644
--- a/WebCore/editing/Editor.cpp
+++ b/WebCore/editing/Editor.cpp
@@ -2864,6 +2864,7 @@ void Editor::handleRejectedCorrection()
         return;
 
     replacedRange->startContainer()->document()->markers()->addMarker(replacedRange, DocumentMarker::RejectedCorrection, m_stringToBeReplacedByCorrection);
+    m_rangeToBeReplacedByCorrection.clear();
 }
 
 void Editor::startCorrectionPanelTimer()
diff --git a/WebCore/manual-tests/autocorrection/autocorrection-cancelled-by-ESC.html b/WebCore/manual-tests/autocorrection/autocorrection-cancelled-by-ESC.html
new file mode 100644
index 0000000..185e5c6
--- /dev/null
+++ b/WebCore/manual-tests/autocorrection/autocorrection-cancelled-by-ESC.html
@@ -0,0 +1,50 @@
+<html>
+<head>
+
+<style>
+.editing {
+    border: 2px solid red;
+    padding: 12px;
+    font-size: 24px;
+}
+</style>
+<script src=../../../LayoutTests/editing/editing.js language="JavaScript" type="text/JavaScript" ></script>
+
+<script>
+function editingTest() {
+    typeCharacterCommand('t');
+    typeCharacterCommand('h');
+    typeCharacterCommand('e');
+    typeCharacterCommand(' ');
+    typeCharacterCommand('c');
+    typeCharacterCommand('o');
+    typeCharacterCommand('l');
+    typeCharacterCommand('l');
+    typeCharacterCommand('a');
+    typeCharacterCommand('p');
+    typeCharacterCommand('s');
+}
+
+</script>
+
+<title>Autocorrection Cancellation By ESC Test</title>
+</head>
+<body>
+<div><p>This test verifies that autocorrection is not applied when user dismisses correction panel by pressing
+ESC key.</p>
+<p>After seeing the correction panel, press ESC key, then press space. You should see the phrase "the collaps" 
+where "collaps" has red mispell underline. </p>
+<p  style="color:green">Note, this test can fail due to user specific spell checking data. If the user has previously 
+dismissed 'collapse' as the correct spelling of 'collaps' several times, the spell checker will not provide 
+'collapse' as a suggestion anymore. To fix this, remove all files in ~/Library/Spelling.</p>
+<div contenteditable id="root" class="editing">
+<span id="test"></span>
+</div>
+
+
+<script>
+runEditingTest();
+</script>
+
+</body>
+</html>

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list