Changeset 108772 in webkit


Ignore:
Timestamp:
Feb 24, 2012 4:32:27 AM (12 years ago)
Author:
shinyak@chromium.org
Message:

SpellCheckRequest needs to know the context where the spellcheck happened.
https://bugs.webkit.org/show_bug.cgi?id=79320

Reviewed by Hajime Morita.

Source/WebCore:

WebKit clients should be able to get the context how the spellcheck happended.
For example, WebKit clients may want to change the behavior by a spellcheck request is
invoked in typing or in pasting.

This patch added an enum in SpellCheckRequest so that WebKit clients can understand the context.

  • editing/Editor.cpp:

(WebCore::Editor::replaceSelectionWithFragment):
(WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges):

  • editing/SpellChecker.cpp:

(WebCore::SpellCheckRequest::SpellCheckRequest):
(WebCore::SpellCheckRequest::create):
(WebCore::SpellChecker::invokeRequest):

  • editing/SpellChecker.h:

(SpellCheckRequest):
(WebCore::SpellCheckRequest::textCheckingRequest):
(WebCore::SpellCheckRequest::processType):

  • loader/EmptyClients.h:

(WebCore::EmptyTextCheckerClient::requestCheckingOfString):

  • platform/text/TextCheckerClient.h:

(WebCore):
(TextCheckerClient):

  • platform/text/TextChecking.h:

(TextCheckingRequest):
(WebCore::TextCheckingRequest::TextCheckingRequest):
(WebCore::TextCheckingRequest::setSequence):
(WebCore::TextCheckingRequest::sequence):
(WebCore::TextCheckingRequest::text):
(WebCore::TextCheckingRequest::mask):
(WebCore::TextCheckingRequest::processType):
(WebCore):

Source/WebKit/blackberry:

  • WebCoreSupport/EditorClientBlackBerry.cpp:

(WebCore::EditorClientBlackBerry::requestCheckingOfString):

  • WebCoreSupport/EditorClientBlackBerry.h:

(EditorClientBlackBerry):

Source/WebKit/chromium:

  • src/EditorClientImpl.cpp:

(WebKit::EditorClientImpl::requestCheckingOfString):

  • src/EditorClientImpl.h:

(EditorClientImpl):

  • src/WebFrameImpl.cpp:

(WebKit::WebFrameImpl::requestTextChecking):

Source/WebKit/efl:

  • WebCoreSupport/EditorClientEfl.h:

(WebCore::EditorClientEfl::requestCheckingOfString):

Source/WebKit/gtk:

  • WebCoreSupport/TextCheckerClientGtk.h:

(WebKit::TextCheckerClientGtk::requestCheckingOfString):

Source/WebKit/mac:

  • WebCoreSupport/WebEditorClient.h:
  • WebCoreSupport/WebEditorClient.mm:

(WebEditorClient::requestCheckingOfString):

Source/WebKit/qt:

  • WebCoreSupport/TextCheckerClientQt.h:

(WebCore::TextCheckerClientQt::requestCheckingOfString):

Source/WebKit/win:

  • WebCoreSupport/WebEditorClient.h:

(WebEditorClient::requestCheckingOfString):
(WebEditorClient):

Source/WebKit/wince:

  • WebCoreSupport/EditorClientWinCE.h:

(WebKit::EditorClientWinCE::requestCheckingOfString):

Source/WebKit/wx:

  • WebKitSupport/EditorClientWx.h:

(WebCore::EditorClientWx::requestCheckingOfString):

Source/WebKit2:

  • WebProcess/WebCoreSupport/WebEditorClient.cpp:

(WebKit::WebEditorClient::requestCheckingOfString):

  • WebProcess/WebCoreSupport/WebEditorClient.h:
Location:
trunk/Source
Files:
32 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r108770 r108772  
     12012-02-24  Shinya Kawanaka  <shinyak@chromium.org>
     2
     3        SpellCheckRequest needs to know the context where the spellcheck happened.
     4        https://bugs.webkit.org/show_bug.cgi?id=79320
     5
     6        Reviewed by Hajime Morita.
     7
     8        WebKit clients should be able to get the context how the spellcheck happended.
     9        For example, WebKit clients may want to change the behavior by a spellcheck request is
     10        invoked in typing or in pasting.
     11
     12        This patch added an enum in SpellCheckRequest so that WebKit clients can understand the context.
     13
     14        * editing/Editor.cpp:
     15        (WebCore::Editor::replaceSelectionWithFragment):
     16        (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges):
     17        * editing/SpellChecker.cpp:
     18        (WebCore::SpellCheckRequest::SpellCheckRequest):
     19        (WebCore::SpellCheckRequest::create):
     20        (WebCore::SpellChecker::invokeRequest):
     21        * editing/SpellChecker.h:
     22        (SpellCheckRequest):
     23        (WebCore::SpellCheckRequest::textCheckingRequest):
     24        (WebCore::SpellCheckRequest::processType):
     25        * loader/EmptyClients.h:
     26        (WebCore::EmptyTextCheckerClient::requestCheckingOfString):
     27        * platform/text/TextCheckerClient.h:
     28        (WebCore):
     29        (TextCheckerClient):
     30        * platform/text/TextChecking.h:
     31        (TextCheckingRequest):
     32        (WebCore::TextCheckingRequest::TextCheckingRequest):
     33        (WebCore::TextCheckingRequest::setSequence):
     34        (WebCore::TextCheckingRequest::sequence):
     35        (WebCore::TextCheckingRequest::text):
     36        (WebCore::TextCheckingRequest::mask):
     37        (WebCore::TextCheckingRequest::processType):
     38        (WebCore):
     39
    1402012-02-24  Hayato Ito  <hayato@chromium.org>
    241
  • trunk/Source/WebCore/editing/Editor.cpp

    r108462 r108772  
    419419
    420420    RefPtr<Range> rangeToCheck = Range::create(m_frame->document(), firstPositionInNode(nodeToCheck), lastPositionInNode(nodeToCheck));
    421     m_spellChecker->requestCheckingFor(SpellCheckRequest::create(resolveTextCheckingTypeMask(TextCheckingTypeSpelling | TextCheckingTypeGrammar), rangeToCheck, rangeToCheck));
     421    m_spellChecker->requestCheckingFor(SpellCheckRequest::create(resolveTextCheckingTypeMask(TextCheckingTypeSpelling | TextCheckingTypeGrammar), TextCheckingProcessBatch, rangeToCheck, rangeToCheck));
    422422}
    423423
     
    19361936
    19371937    // In asynchronous mode, we intentionally check paragraph-wide sentence.
    1938     RefPtr<SpellCheckRequest> request = SpellCheckRequest::create(resolveTextCheckingTypeMask(textCheckingOptions), asynchronous ? paragraphRange : rangeToCheck, paragraphRange);
     1938    RefPtr<SpellCheckRequest> request = SpellCheckRequest::create(resolveTextCheckingTypeMask(textCheckingOptions), TextCheckingProcessIncremental, asynchronous ? paragraphRange : rangeToCheck, paragraphRange);
    19391939
    19401940    if (asynchronous) {
  • trunk/Source/WebCore/editing/SpellChecker.cpp

    r102553 r108772  
    4848static const int unrequestedSequence = -1;
    4949
    50 SpellCheckRequest::SpellCheckRequest(int sequence, PassRefPtr<Range> checkingRange, PassRefPtr<Range> paragraphRange, const String& text, TextCheckingTypeMask mask)
     50SpellCheckRequest::SpellCheckRequest(int sequence, PassRefPtr<Range> checkingRange, PassRefPtr<Range> paragraphRange, const String& text, TextCheckingTypeMask mask, TextCheckingProcessType processType)
    5151    : m_sequence(sequence)
     52    , m_text(text)
     53    , m_mask(mask)
     54    , m_processType(processType)
    5255    , m_checkingRange(checkingRange)
    5356    , m_paragraphRange(paragraphRange)
    54     , m_text(text)
    55     , m_mask(mask)
    5657    , m_rootEditableElement(m_checkingRange->startContainer()->rootEditableElement())
    5758{
     
    6364
    6465// static
    65 PassRefPtr<SpellCheckRequest> SpellCheckRequest::create(TextCheckingTypeMask textCheckingOptions, PassRefPtr<Range> checkingRange, PassRefPtr<Range> paragraphRange)
     66PassRefPtr<SpellCheckRequest> SpellCheckRequest::create(TextCheckingTypeMask textCheckingOptions, TextCheckingProcessType processType, PassRefPtr<Range> checkingRange, PassRefPtr<Range> paragraphRange)
    6667{
    6768    ASSERT(checkingRange);
     
    7273        return PassRefPtr<SpellCheckRequest>();
    7374
    74     return adoptRef(new SpellCheckRequest(unrequestedSequence, checkingRange, paragraphRange, text, textCheckingOptions));
     75    return adoptRef(new SpellCheckRequest(unrequestedSequence, checkingRange, paragraphRange, text, textCheckingOptions, processType));
    7576}
    7677
     
    146147
    147148    m_processingRequest = request;
    148     client()->requestCheckingOfString(this, m_processingRequest->sequence(), m_processingRequest->mask(), m_processingRequest->text());
     149    client()->requestCheckingOfString(this, m_processingRequest->textCheckingRequest());
    149150}
    150151
  • trunk/Source/WebCore/editing/SpellChecker.h

    r102328 r108772  
    4747class SpellCheckRequest : public RefCounted<SpellCheckRequest> {
    4848public:
    49     SpellCheckRequest(int sequence, PassRefPtr<Range> checkingRange, PassRefPtr<Range> paragraphRange, const String&, TextCheckingTypeMask);
     49    SpellCheckRequest(int sequence, PassRefPtr<Range> checkingRange, PassRefPtr<Range> paragraphRange, const String&, TextCheckingTypeMask, TextCheckingProcessType);
    5050    ~SpellCheckRequest();
    5151
    52     static PassRefPtr<SpellCheckRequest> create(TextCheckingTypeMask, PassRefPtr<Range> checkingRange, PassRefPtr<Range> paragraphRange);
     52    static PassRefPtr<SpellCheckRequest> create(TextCheckingTypeMask, TextCheckingProcessType, PassRefPtr<Range> checkingRange, PassRefPtr<Range> paragraphRange);
     53
     54    TextCheckingRequest textCheckingRequest() const;
    5355
    5456    void setSequence(int sequence) { m_sequence = sequence; }
     
    5860    const String& text() const { return m_text; }
    5961    TextCheckingTypeMask mask() const { return m_mask; }
     62    TextCheckingProcessType processType() const { return m_processType; }
    6063    PassRefPtr<Element> rootEditableElement() const { return m_rootEditableElement; }
    6164private:
    62 
    6365    int m_sequence;
     66    String m_text;
     67    TextCheckingTypeMask m_mask;
     68    TextCheckingProcessType m_processType;
    6469    RefPtr<Range> m_checkingRange;
    6570    RefPtr<Range> m_paragraphRange;
    66     String m_text;
    67     TextCheckingTypeMask m_mask;
    6871    RefPtr<Element> m_rootEditableElement;
    6972};
     
    110113};
    111114
     115inline TextCheckingRequest SpellCheckRequest::textCheckingRequest() const
     116{
     117    return TextCheckingRequest(m_sequence, m_text, m_mask, m_processType);
     118}
     119
    112120} // namespace WebCore
    113121
  • trunk/Source/WebCore/loader/EmptyClients.h

    r108462 r108772  
    433433
    434434    virtual void getGuessesForWord(const String&, const String&, Vector<String>&) { }
    435     virtual void requestCheckingOfString(SpellChecker*, int, TextCheckingTypeMask, const String&) { }
     435    virtual void requestCheckingOfString(SpellChecker*, const TextCheckingRequest&) { }
    436436};
    437437
  • trunk/Source/WebCore/platform/text/TextCheckerClient.h

    r95901 r108772  
    3838
    3939class SpellChecker;
     40class TextCheckingRequest;
    4041
    4142struct GrammarDetail {
     
    7273    // identification. Noramlly it's the text surrounding the "word" for which we are getting correction suggestions.
    7374    virtual void getGuessesForWord(const String& word, const String& context, Vector<String>& guesses) = 0;
    74     virtual void requestCheckingOfString(SpellChecker*, int, TextCheckingTypeMask, const String&) = 0;
     75    virtual void requestCheckingOfString(SpellChecker*, const TextCheckingRequest&) = 0;
    7576};
    7677
  • trunk/Source/WebCore/platform/text/TextChecking.h

    r95901 r108772  
    3232#define TextChecking_h
    3333
     34#include <wtf/text/WTFString.h>
     35
    3436namespace WebCore {
    3537
     
    6264typedef unsigned TextCheckingTypeMask;
    6365
     66enum TextCheckingProcessType {
     67    TextCheckingProcessBatch,
     68    TextCheckingProcessIncremental
     69};
     70
     71class TextCheckingRequest {
     72public:
     73    TextCheckingRequest(int sequence, String text, TextCheckingTypeMask mask, TextCheckingProcessType processType)
     74        : m_sequence(sequence)
     75        , m_text(text)
     76        , m_mask(mask)
     77        , m_processType(processType)
     78    {
     79    }
     80
     81    void setSequence(int sequence) { m_sequence = sequence; }
     82    int sequence() const { return m_sequence; }
     83    String text() const { return m_text; }
     84    TextCheckingTypeMask mask() const { return m_mask; }
     85    TextCheckingProcessType processType() const { return m_processType; }
     86
     87private:
     88    int m_sequence;
     89    String m_text;
     90    TextCheckingTypeMask m_mask;
     91    TextCheckingProcessType m_processType;
     92};
     93
    6494}
    6595
  • trunk/Source/WebKit/blackberry/ChangeLog

    r108763 r108772  
     12012-02-24  Shinya Kawanaka  <shinyak@chromium.org>
     2
     3        SpellCheckRequest needs to know the context where the spellcheck happened.
     4        https://bugs.webkit.org/show_bug.cgi?id=79320
     5
     6        Reviewed by Hajime Morita.
     7
     8        * WebCoreSupport/EditorClientBlackBerry.cpp:
     9        (WebCore::EditorClientBlackBerry::requestCheckingOfString):
     10        * WebCoreSupport/EditorClientBlackBerry.h:
     11        (EditorClientBlackBerry):
     12
    1132012-02-24  Charles Wei  <charles.wei@torchmobile.com.cn>
    214
  • trunk/Source/WebKit/blackberry/WebCoreSupport/EditorClientBlackBerry.cpp

    r108462 r108772  
    559559}
    560560
    561 void EditorClientBlackBerry::requestCheckingOfString(SpellChecker*, int, TextCheckingTypeMask, const String&)
     561void EditorClientBlackBerry::requestCheckingOfString(SpellChecker*, const TextCheckingRequest&)
    562562{
    563563    notImplemented();
  • trunk/Source/WebKit/blackberry/WebCoreSupport/EditorClientBlackBerry.h

    r108462 r108772  
    8585    virtual void checkGrammarOfString(const UChar*, int, Vector<GrammarDetail, 0u>&, int*, int*);
    8686    virtual void getGuessesForWord(const String&, const String&, Vector<String>&);
    87     virtual void requestCheckingOfString(SpellChecker*, int, TextCheckingTypeMask, const String&);
     87    virtual void requestCheckingOfString(SpellChecker*, const TextCheckingRequest&);
    8888
    8989    virtual TextCheckerClient* textChecker();
  • trunk/Source/WebKit/chromium/ChangeLog

    r108732 r108772  
     12012-02-24  Shinya Kawanaka  <shinyak@chromium.org>
     2
     3        SpellCheckRequest needs to know the context where the spellcheck happened.
     4        https://bugs.webkit.org/show_bug.cgi?id=79320
     5
     6        Reviewed by Hajime Morita.
     7
     8        * src/EditorClientImpl.cpp:
     9        (WebKit::EditorClientImpl::requestCheckingOfString):
     10        * src/EditorClientImpl.h:
     11        (EditorClientImpl):
     12        * src/WebFrameImpl.cpp:
     13        (WebKit::WebFrameImpl::requestTextChecking):
     14
    1152012-02-23  Sheriff Bot  <webkit.review.bot@gmail.com>
    216
  • trunk/Source/WebKit/chromium/src/EditorClientImpl.cpp

    r108462 r108772  
    730730}
    731731
    732 void EditorClientImpl::requestCheckingOfString(SpellChecker* sender, int identifier, TextCheckingTypeMask, const String& text)
     732void EditorClientImpl::requestCheckingOfString(SpellChecker* sender, const WebCore::TextCheckingRequest& request)
    733733{
    734734    if (m_webView->spellCheckClient())
    735         m_webView->spellCheckClient()->requestCheckingOfText(text, new WebTextCheckingCompletionImpl(identifier, sender));
     735        m_webView->spellCheckClient()->requestCheckingOfText(request.text(), new WebTextCheckingCompletionImpl(request.sequence(), sender));
    736736}
    737737
  • trunk/Source/WebKit/chromium/src/EditorClientImpl.h

    r108462 r108772  
    110110    virtual void willSetInputMethodState();
    111111    virtual void setInputMethodState(bool enabled);
    112     virtual void requestCheckingOfString(WebCore::SpellChecker*, int, WebCore::TextCheckingTypeMask, const WTF::String&);
     112    virtual void requestCheckingOfString(WebCore::SpellChecker*, const WebCore::TextCheckingRequest&);
    113113
    114114    virtual WebCore::TextCheckerClient* textChecker() { return this; }
  • trunk/Source/WebKit/chromium/src/WebFrameImpl.cpp

    r107682 r108772  
    13021302    RefPtr<Range> rangeToCheck = rangeOfContents(const_cast<Element*>(webElem.constUnwrap<Element>()));
    13031303
    1304     frame()->editor()->spellChecker()->requestCheckingFor(SpellCheckRequest::create(TextCheckingTypeSpelling | TextCheckingTypeGrammar, rangeToCheck, rangeToCheck));
     1304    frame()->editor()->spellChecker()->requestCheckingFor(SpellCheckRequest::create(TextCheckingTypeSpelling | TextCheckingTypeGrammar, TextCheckingProcessBatch, rangeToCheck, rangeToCheck));
    13051305}
    13061306
  • trunk/Source/WebKit/efl/ChangeLog

    r108562 r108772  
     12012-02-24  Shinya Kawanaka  <shinyak@chromium.org>
     2
     3        SpellCheckRequest needs to know the context where the spellcheck happened.
     4        https://bugs.webkit.org/show_bug.cgi?id=79320
     5
     6        Reviewed by Hajime Morita.
     7
     8        * WebCoreSupport/EditorClientEfl.h:
     9        (WebCore::EditorClientEfl::requestCheckingOfString):
     10
    1112012-02-21  Ryosuke Niwa  <rniwa@webkit.org>
    212
  • trunk/Source/WebKit/efl/WebCoreSupport/EditorClientEfl.h

    r108462 r108772  
    121121    virtual void willSetInputMethodState();
    122122    virtual void setInputMethodState(bool enabled);
    123     virtual void requestCheckingOfString(WebCore::SpellChecker*, int, WebCore::TextCheckingTypeMask, const WTF::String&) { }
     123    virtual void requestCheckingOfString(WebCore::SpellChecker*, const WebCore::TextCheckingRequest&) { }
    124124    virtual TextCheckerClient* textChecker() { return this; }
    125125
  • trunk/Source/WebKit/gtk/ChangeLog

    r108628 r108772  
     12012-02-24  Shinya Kawanaka  <shinyak@chromium.org>
     2
     3        SpellCheckRequest needs to know the context where the spellcheck happened.
     4        https://bugs.webkit.org/show_bug.cgi?id=79320
     5
     6        Reviewed by Hajime Morita.
     7
     8        * WebCoreSupport/TextCheckerClientGtk.h:
     9        (WebKit::TextCheckerClientGtk::requestCheckingOfString):
     10
    1112012-02-23  ChangSeok Oh  <shivamidow@gmail.com>
    212
  • trunk/Source/WebKit/gtk/WebCoreSupport/TextCheckerClientGtk.h

    r95901 r108772  
    4949        virtual void checkGrammarOfString(const UChar*, int length, WTF::Vector<WebCore::GrammarDetail>&, int* badGrammarLocation, int* badGrammarLength);
    5050        virtual void getGuessesForWord(const WTF::String& word, const WTF::String& context, WTF::Vector<WTF::String>& guesses);
    51         virtual void requestCheckingOfString(WebCore::SpellChecker*, int, WebCore::TextCheckingTypeMask, const WTF::String&) {}
     51        virtual void requestCheckingOfString(WebCore::SpellChecker*, const WebCore::TextCheckingRequest&) { }
    5252
    5353        void updateSpellCheckingLanguage(const char*);
  • trunk/Source/WebKit/mac/ChangeLog

    r108730 r108772  
     12012-02-24  Shinya Kawanaka  <shinyak@chromium.org>
     2
     3        SpellCheckRequest needs to know the context where the spellcheck happened.
     4        https://bugs.webkit.org/show_bug.cgi?id=79320
     5
     6        Reviewed by Hajime Morita.
     7
     8        * WebCoreSupport/WebEditorClient.h:
     9        * WebCoreSupport/WebEditorClient.mm:
     10        (WebEditorClient::requestCheckingOfString):
     11
    1122012-02-23  Andy Estes  <aestes@apple.com>
    213
  • trunk/Source/WebKit/mac/WebCoreSupport/WebEditorClient.h

    r108462 r108772  
    136136    virtual void willSetInputMethodState() OVERRIDE;
    137137    virtual void setInputMethodState(bool enabled) OVERRIDE;
    138     virtual void requestCheckingOfString(WebCore::SpellChecker*, int, WebCore::TextCheckingTypeMask, const WTF::String&) OVERRIDE;
     138    virtual void requestCheckingOfString(WebCore::SpellChecker*, const WebCore::TextCheckingRequest&) OVERRIDE;
    139139#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
    140140    virtual void showCorrectionPanel(WebCore::CorrectionPanelInfo::PanelType, const WebCore::FloatRect& boundingBoxOfReplacedString, const String& replacedString, const String& replacementString, const Vector<String>& alternativeReplacementStrings) OVERRIDE;
  • trunk/Source/WebKit/mac/WebCoreSupport/WebEditorClient.mm

    r108462 r108772  
    973973#endif
    974974
    975 void WebEditorClient::requestCheckingOfString(WebCore::SpellChecker* sender, int sequence, WebCore::TextCheckingTypeMask checkingTypes, const String& text)
     975void WebEditorClient::requestCheckingOfString(WebCore::SpellChecker* sender, const WebCore::TextCheckingRequest& request)
    976976{
    977977#ifndef BUILDING_ON_LEOPARD
    978     NSRange range = NSMakeRange(0, text.length());
     978    NSRange range = NSMakeRange(0, request.text().length());
    979979    NSRunLoop* currentLoop = [NSRunLoop currentRunLoop];
    980     [[NSSpellChecker sharedSpellChecker] requestCheckingOfString:text range:range types:NSTextCheckingAllSystemTypes options:0 inSpellDocumentWithTag:0
     980    [[NSSpellChecker sharedSpellChecker] requestCheckingOfString:request.text() range:range types:NSTextCheckingAllSystemTypes options:0 inSpellDocumentWithTag:0
    981981                                         completionHandler:^(NSInteger, NSArray* results, NSOrthography*, NSInteger) {
    982982            [currentLoop performSelector:@selector(perform)
    983                                   target:[[[WebEditorSpellCheckResponder alloc] initWithSender:sender sequence:sequence types:checkingTypes results:results] autorelease]
     983                                  target:[[[WebEditorSpellCheckResponder alloc] initWithSender:sender sequence:request.sequence() types:request.mask() results:results] autorelease]
    984984                                argument:nil order:0 modes:[NSArray arrayWithObject:NSDefaultRunLoopMode]];
    985985        }];
  • trunk/Source/WebKit/qt/ChangeLog

    r108643 r108772  
     12012-02-24  Shinya Kawanaka  <shinyak@chromium.org>
     2
     3        SpellCheckRequest needs to know the context where the spellcheck happened.
     4        https://bugs.webkit.org/show_bug.cgi?id=79320
     5
     6        Reviewed by Hajime Morita.
     7
     8        * WebCoreSupport/TextCheckerClientQt.h:
     9        (WebCore::TextCheckerClientQt::requestCheckingOfString):
     10
    1112012-02-23  Simon Hausmann  <simon.hausmann@nokia.com>
    212
  • trunk/Source/WebKit/qt/WebCoreSupport/TextCheckerClientQt.h

    r95901 r108772  
    4848    virtual void checkGrammarOfString(const UChar*, int length, Vector<GrammarDetail>&, int* badGrammarLocation, int* badGrammarLength);
    4949    virtual void getGuessesForWord(const String& word, const String& context, Vector<String>& guesses);
    50     virtual void requestCheckingOfString(SpellChecker*, int, TextCheckingTypeMask, const String&) { }
     50    virtual void requestCheckingOfString(SpellChecker*, const TextCheckingRequest&) { }
    5151
    5252    virtual bool isContinousSpellCheckingEnabled();
  • trunk/Source/WebKit/win/ChangeLog

    r108562 r108772  
     12012-02-24  Shinya Kawanaka  <shinyak@chromium.org>
     2
     3        SpellCheckRequest needs to know the context where the spellcheck happened.
     4        https://bugs.webkit.org/show_bug.cgi?id=79320
     5
     6        Reviewed by Hajime Morita.
     7
     8        * WebCoreSupport/WebEditorClient.h:
     9        (WebEditorClient::requestCheckingOfString):
     10        (WebEditorClient):
     11
    1122012-02-21  Ryosuke Niwa  <rniwa@webkit.org>
    213
  • trunk/Source/WebKit/win/WebCoreSupport/WebEditorClient.h

    r108462 r108772  
    111111    virtual void willSetInputMethodState();
    112112    virtual void setInputMethodState(bool);
    113     virtual void requestCheckingOfString(WebCore::SpellChecker*, int, WebCore::TextCheckingTypeMask, const WTF::String&) {}
     113    virtual void requestCheckingOfString(WebCore::SpellChecker*, const WebCore::TextCheckingRequest&) { }
     114
    114115    virtual WebCore::TextCheckerClient* textChecker() { return this; }
    115116
  • trunk/Source/WebKit/wince/ChangeLog

    r108633 r108772  
     12012-02-24  Shinya Kawanaka  <shinyak@chromium.org>
     2
     3        SpellCheckRequest needs to know the context where the spellcheck happened.
     4        https://bugs.webkit.org/show_bug.cgi?id=79320
     5
     6        Reviewed by Hajime Morita.
     7
     8        * WebCoreSupport/EditorClientWinCE.h:
     9        (WebKit::EditorClientWinCE::requestCheckingOfString):
     10
    1112012-02-23  Patrick Gansterer  <paroga@webkit.org>
    212
  • trunk/Source/WebKit/wince/WebCoreSupport/EditorClientWinCE.h

    r108633 r108772  
    102102    virtual void willSetInputMethodState();
    103103    virtual void setInputMethodState(bool);
    104     virtual void requestCheckingOfString(WebCore::SpellChecker*, int, WebCore::TextCheckingTypeMask, const WTF::String&) {}
     104    virtual void requestCheckingOfString(WebCore::SpellChecker*, const WebCore::TextCheckingRequest&) { }
    105105    virtual WebCore::TextCheckerClient* textChecker() { return this; }
    106106
  • trunk/Source/WebKit/wx/ChangeLog

    r108562 r108772  
     12012-02-24  Shinya Kawanaka  <shinyak@chromium.org>
     2
     3        SpellCheckRequest needs to know the context where the spellcheck happened.
     4        https://bugs.webkit.org/show_bug.cgi?id=79320
     5
     6        Reviewed by Hajime Morita.
     7
     8        * WebKitSupport/EditorClientWx.h:
     9        (WebCore::EditorClientWx::requestCheckingOfString):
     10
    1112012-02-21  Ryosuke Niwa  <rniwa@webkit.org>
    212
  • trunk/Source/WebKit/wx/WebKitSupport/EditorClientWx.h

    r108462 r108772  
    115115    virtual void willSetInputMethodState();
    116116    virtual void setInputMethodState(bool enabled);
    117     virtual void requestCheckingOfString(WebCore::SpellChecker*, int, WebCore::TextCheckingTypeMask, const WTF::String&) {}
     117    virtual void requestCheckingOfString(WebCore::SpellChecker*, const WebCore::TextCheckingRequest&) { }
    118118    virtual TextCheckerClient* textChecker() { return this; }
    119119
  • trunk/Source/WebKit2/ChangeLog

    r108771 r108772  
     12012-02-24  Shinya Kawanaka  <shinyak@chromium.org>
     2
     3        SpellCheckRequest needs to know the context where the spellcheck happened.
     4        https://bugs.webkit.org/show_bug.cgi?id=79320
     5
     6        Reviewed by Hajime Morita.
     7
     8        * WebProcess/WebCoreSupport/WebEditorClient.cpp:
     9        (WebKit::WebEditorClient::requestCheckingOfString):
     10        * WebProcess/WebCoreSupport/WebEditorClient.h:
     11
    1122012-02-23  Kenneth Rohde Christiansen  <kenneth@webkit.org>
    213
  • trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebEditorClient.cpp

    r108462 r108772  
    448448}
    449449
    450 void WebEditorClient::requestCheckingOfString(WebCore::SpellChecker*, int, WebCore::TextCheckingTypeMask, const WTF::String&)
     450void WebEditorClient::requestCheckingOfString(WebCore::SpellChecker*, const WebCore::TextCheckingRequest&)
    451451{
    452452    notImplemented();
  • trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebEditorClient.h

    r108462 r108772  
    142142    virtual void willSetInputMethodState() OVERRIDE;
    143143    virtual void setInputMethodState(bool enabled) OVERRIDE;
    144     virtual void requestCheckingOfString(WebCore::SpellChecker*, int, WebCore::TextCheckingTypeMask, const WTF::String&) OVERRIDE;
     144    virtual void requestCheckingOfString(WebCore::SpellChecker*, const WebCore::TextCheckingRequest&) OVERRIDE;
    145145#if PLATFORM(MAC) && !defined(BUILDING_ON_SNOW_LEOPARD)
    146146    virtual void showCorrectionPanel(WebCore::CorrectionPanelInfo::PanelType, const WebCore::FloatRect& boundingBoxOfReplacedString, const String& replacedString, const String& replacementString, const Vector<String>& alternativeReplacementStrings) OVERRIDE;
Note: See TracChangeset for help on using the changeset viewer.