Changeset 141650 in webkit


Ignore:
Timestamp:
Feb 1, 2013 3:03:57 PM (11 years ago)
Author:
commit-queue@webkit.org
Message:

Source/WebKit/chromium: [Chromium] Ignore punctuation in spellcheck
https://bugs.webkit.org/show_bug.cgi?id=108511

Patch by Rouslan Solomakhin <rouslan@chromium.org> on 2013-02-01
Reviewed by Tony Chang.

  • src/ContextMenuClientImpl.cpp:

(WebKit::IsWhiteSpaceOrPunctuation): Added utility function to detect whitespace or punctuation.
(WebKit::selectMisspellingAsync): Ignore punctuation when selecting the misspelling.

LayoutTests: [Chromium] Expect spellcheck to ignore punctuation
https://bugs.webkit.org/show_bug.cgi?id=108511

Patch by Rouslan Solomakhin <rouslan@chromium.org> on 2013-02-01
Reviewed by Tony Chang.

  • platform/chromium/TestExpectations: Expect spellcheck to ignore punctuation.
Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r141647 r141650  
     12013-02-01  Rouslan Solomakhin  <rouslan@chromium.org>
     2
     3        [Chromium] Expect spellcheck to ignore punctuation
     4        https://bugs.webkit.org/show_bug.cgi?id=108511
     5
     6        Reviewed by Tony Chang.
     7
     8        * platform/chromium/TestExpectations: Expect spellcheck to ignore punctuation.
     9
    1102013-02-01  Andrey Lushnikov  <lushnikov@chromium.org>
    211
  • trunk/LayoutTests/platform/chromium/TestExpectations

    r141645 r141650  
    43464346webkit.org/b/108286 platform/chromium/virtual/softwarecompositing/geometry/fixed-position-iframe-composited-page-scale-down.html [ ImageOnlyFailure ]
    43474347
    4348 # Spellchecker behavior tests.
    4349 webkit.org/b/108370 editing/spelling/spelling-double-clicked-word-with-underscores.html [ Failure ]
    4350 webkit.org/b/108370 editing/spelling/spelling-with-punctuation-selection.html [ Failure ]
    4351 webkit.org/b/108370 editing/spelling/spelling-with-underscore-selection.html [ Failure ]
    4352 
    43534348webkit.org/b/108424 media/video-error-does-not-exist.html [ Failure Crash ]
    43544349webkit.org/b/108566 platform/chromium/fast/forms/calendar-picker/calendar-picker-key-operations.html [ Failure ]
  • trunk/Source/WebKit/chromium/ChangeLog

    r141637 r141650  
     12013-02-01  Rouslan Solomakhin  <rouslan@chromium.org>
     2
     3        [Chromium] Ignore punctuation in spellcheck
     4        https://bugs.webkit.org/show_bug.cgi?id=108511
     5
     6        Reviewed by Tony Chang.
     7
     8        * src/ContextMenuClientImpl.cpp:
     9        (WebKit::IsWhiteSpaceOrPunctuation): Added utility function to detect whitespace or punctuation.
     10        (WebKit::selectMisspellingAsync): Ignore punctuation when selecting the misspelling.
     11
    1122013-02-01  Philip Rogers  <pdr@google.com>
    213
  • trunk/Source/WebKit/chromium/src/ContextMenuClientImpl.cpp

    r141608 r141650  
    145145}
    146146
     147static bool IsWhiteSpaceOrPunctuation(UChar c)
     148{
     149    return isSpaceOrNewline(c) || WTF::Unicode::isPunct(c);
     150}
     151
    147152static String selectMisspellingAsync(Frame* selectedFrame, Vector<DocumentMarker*>& markers)
    148153{
     
    167172    }
    168173
    169     if (markerRange->text().stripWhiteSpace() != selectionRange->text().stripWhiteSpace())
     174    if (markerRange->text().stripWhiteSpace(&IsWhiteSpaceOrPunctuation) != selectionRange->text().stripWhiteSpace(&IsWhiteSpaceOrPunctuation))
    170175        return String();
    171176
Note: See TracChangeset for help on using the changeset viewer.