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

Unified Diff: chrome/browser/renderer_context_menu/spelling_menu_observer.cc

Issue 222783004: Move textual replacement to WebContents. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/browser/renderer_host/chrome_render_widget_host_view_mac_delegate.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/renderer_context_menu/spelling_menu_observer.cc
diff --git a/chrome/browser/renderer_context_menu/spelling_menu_observer.cc b/chrome/browser/renderer_context_menu/spelling_menu_observer.cc
index c95aee987a658324118c1170c8fd99e2ccf1b9c8..16ee4e76a2fd9f938291c9e4e7e3ad80c6312657 100644
--- a/chrome/browser/renderer_context_menu/spelling_menu_observer.cc
+++ b/chrome/browser/renderer_context_menu/spelling_menu_observer.cc
@@ -251,7 +251,7 @@ void SpellingMenuObserver::ExecuteCommand(int command_id) {
if (command_id >= IDC_SPELLCHECK_SUGGESTION_0 &&
command_id <= IDC_SPELLCHECK_SUGGESTION_LAST) {
int suggestion_index = command_id - IDC_SPELLCHECK_SUGGESTION_0;
- proxy_->GetRenderViewHost()->ReplaceMisspelling(
+ proxy_->GetWebContents()->ReplaceMisspelling(
suggestions_[suggestion_index]);
// GetSpellCheckHost() can return null when the suggested word is provided
// by Web SpellCheck API.
@@ -273,7 +273,7 @@ void SpellingMenuObserver::ExecuteCommand(int command_id) {
// the misspelled word with the suggestion and add it to our custom-word
// dictionary so this word is not marked as misspelled any longer.
if (command_id == IDC_CONTENT_CONTEXT_SPELLING_SUGGESTION) {
- proxy_->GetRenderViewHost()->ReplaceMisspelling(result_);
+ proxy_->GetWebContents()->ReplaceMisspelling(result_);
misspelled_word_ = result_;
}
« no previous file with comments | « no previous file | chrome/browser/renderer_host/chrome_render_widget_host_view_mac_delegate.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698