Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(381)

Side by Side Diff: chrome/renderer/spellchecker/spellcheck_provider.h

Issue 10536190: Use WebFrame::replaceMisspelledRange() to replace a misspelled range with text. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_RENDERER_SPELLCHECKER_SPELLCHECK_PROVIDER_H_ 5 #ifndef CHROME_RENDERER_SPELLCHECKER_SPELLCHECK_PROVIDER_H_
6 #define CHROME_RENDERER_SPELLCHECKER_SPELLCHECK_PROVIDER_H_ 6 #define CHROME_RENDERER_SPELLCHECKER_SPELLCHECK_PROVIDER_H_
7 #pragma once 7 #pragma once
8 8
9 #include <vector> 9 #include <vector>
10 10
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 virtual void requestCheckingOfText( 70 virtual void requestCheckingOfText(
71 const WebKit::WebString& text, 71 const WebKit::WebString& text,
72 WebKit::WebTextCheckingCompletion* completion) OVERRIDE; 72 WebKit::WebTextCheckingCompletion* completion) OVERRIDE;
73 virtual WebKit::WebString autoCorrectWord( 73 virtual WebKit::WebString autoCorrectWord(
74 const WebKit::WebString& misspelled_word) OVERRIDE; 74 const WebKit::WebString& misspelled_word) OVERRIDE;
75 virtual void showSpellingUI(bool show) OVERRIDE; 75 virtual void showSpellingUI(bool show) OVERRIDE;
76 virtual bool isShowingSpellingUI() OVERRIDE; 76 virtual bool isShowingSpellingUI() OVERRIDE;
77 virtual void updateSpellingUIWithMisspelledWord( 77 virtual void updateSpellingUIWithMisspelledWord(
78 const WebKit::WebString& word) OVERRIDE; 78 const WebKit::WebString& word) OVERRIDE;
79 79
80 // Replaces the misspelling range that covers the cursor with the specified
81 // text. This function does not do anything if there are not any misspelling
82 // ranges that covers the cursor.
83 void OnReplace(const string16& text);
84
80 #if !defined(OS_MACOSX) 85 #if !defined(OS_MACOSX)
81 void OnRespondSpellingService( 86 void OnRespondSpellingService(
82 int identifier, 87 int identifier,
83 int offset, 88 int offset,
84 bool succeeded, 89 bool succeeded,
85 const string16& text, 90 const string16& text,
86 const std::vector<SpellCheckResult>& results); 91 const std::vector<SpellCheckResult>& results);
87 92
88 // Returns whether |text| has word characters, i.e. whether a spellchecker 93 // Returns whether |text| has word characters, i.e. whether a spellchecker
89 // needs to check this text. 94 // needs to check this text.
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 bool spelling_panel_visible_; 128 bool spelling_panel_visible_;
124 129
125 // The ChromeContentRendererClient used to access the SpellChecker. 130 // The ChromeContentRendererClient used to access the SpellChecker.
126 // Weak reference. 131 // Weak reference.
127 chrome::ChromeContentRendererClient* chrome_content_renderer_client_; 132 chrome::ChromeContentRendererClient* chrome_content_renderer_client_;
128 133
129 DISALLOW_COPY_AND_ASSIGN(SpellCheckProvider); 134 DISALLOW_COPY_AND_ASSIGN(SpellCheckProvider);
130 }; 135 };
131 136
132 #endif // CHROME_RENDERER_SPELLCHECKER_SPELLCHECK_PROVIDER_H_ 137 #endif // CHROME_RENDERER_SPELLCHECKER_SPELLCHECK_PROVIDER_H_
OLDNEW
« no previous file with comments | « chrome/common/spellcheck_messages.h ('k') | chrome/renderer/spellchecker/spellcheck_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698