Index: third_party/WebKit/Source/core/editing/SelectionController.cpp |
diff --git a/third_party/WebKit/Source/core/editing/SelectionController.cpp b/third_party/WebKit/Source/core/editing/SelectionController.cpp |
index a64208ae0f600c9af33b12b11279be86dcaef3c9..29b400172e0f0d1d7f0060ccfc41cfa49a8e0804 100644 |
--- a/third_party/WebKit/Source/core/editing/SelectionController.cpp |
+++ b/third_party/WebKit/Source/core/editing/SelectionController.cpp |
@@ -38,6 +38,7 @@ |
#include "core/editing/VisibleSelection.h" |
#include "core/editing/iterators/TextIterator.h" |
#include "core/editing/markers/DocumentMarkerController.h" |
+#include "core/editing/suggestion/TextSuggestionController.h" |
#include "core/events/Event.h" |
#include "core/frame/LocalFrame.h" |
#include "core/frame/LocalFrameView.h" |
@@ -332,7 +333,8 @@ bool SelectionController::HandleSingleClick( |
} |
bool is_handle_visible = false; |
- if (HasEditableStyle(*inner_node)) { |
+ const bool has_editable_style = HasEditableStyle(*inner_node); |
+ if (has_editable_style) { |
const bool is_text_box_empty = |
CreateVisibleSelection(SelectionInFlatTree::Builder() |
.SelectAllChildren(*inner_node) |
@@ -354,6 +356,12 @@ bool SelectionController::HandleSingleClick( |
TextGranularity::kCharacter, |
is_handle_visible ? HandleVisibility::kVisible |
: HandleVisibility::kNotVisible); |
+ |
+ if (has_editable_style && event.Event().FromTouch()) { |
+ frame_->GetTextSuggestionController().HandlePotentialMisspelledWordTap( |
+ visible_pos); |
+ } |
+ |
return false; |
} |