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

Unified Diff: third_party/WebKit/Source/core/page/ContextMenuClient.cpp

Issue 2978823002: [SelectMiss...Async #2] Change ContextMenuClient::SelectMisspellingAsync() to return pair of strings (Closed)
Patch Set: Rebase Created 3 years, 5 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 | « third_party/WebKit/Source/core/editing/spellcheck/SpellChecker.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/page/ContextMenuClient.cpp
diff --git a/third_party/WebKit/Source/core/page/ContextMenuClient.cpp b/third_party/WebKit/Source/core/page/ContextMenuClient.cpp
index 71e3a4d031c23c7e0d86bc8af6a34f2f5617ca6d..5b9fb7070f7459a0115a6315953bf55e1c7a80dd 100644
--- a/third_party/WebKit/Source/core/page/ContextMenuClient.cpp
+++ b/third_party/WebKit/Source/core/page/ContextMenuClient.cpp
@@ -360,9 +360,10 @@ bool ContextMenuClient::ShowContextMenu(const ContextMenu* default_menu,
// suggestions to these markers in the background. Therefore, when a
// user right-clicks a mouse on a word, Chrome just needs to find a
// spelling marker on the word instead of spellchecking it.
- String description;
- data.misspelled_word =
- selected_frame->GetSpellChecker().SelectMisspellingAsync(description);
+ std::pair<String, String> misspelled_word_and_description =
+ selected_frame->GetSpellChecker().SelectMisspellingAsync();
+ data.misspelled_word = misspelled_word_and_description.first;
+ const String& description = misspelled_word_and_description.second;
if (description.length()) {
Vector<String> suggestions;
description.Split('\n', suggestions);
« no previous file with comments | « third_party/WebKit/Source/core/editing/spellcheck/SpellChecker.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698