Index: chrome/renderer/render_view.cc |
=================================================================== |
--- chrome/renderer/render_view.cc (revision 37292) |
+++ chrome/renderer/render_view.cc (working copy) |
@@ -1713,12 +1713,13 @@ |
ContextMenuParams params = ContextMenuParams(data); |
if (!params.misspelled_word.empty() && RenderThread::current()) { |
int misspelled_offset, misspelled_length; |
- bool misspelled = RenderThread::current()->spellchecker()->SpellCheckWord( |
- params.misspelled_word.c_str(), params.misspelled_word.size(), |
- document_tag_, |
- &misspelled_offset, &misspelled_length, |
- ¶ms.dictionary_suggestions); |
- if (!misspelled) |
+ bool spelled_right = RenderThread::current()->spellchecker()-> |
+ SpellCheckWord( |
+ params.misspelled_word.c_str(), params.misspelled_word.size(), |
+ document_tag_, |
+ &misspelled_offset, &misspelled_length, |
+ ¶ms.dictionary_suggestions); |
+ if (spelled_right) |
params.misspelled_word.clear(); |
} |