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

Unified Diff: third_party/WebKit/Source/web/WebViewImpl.cpp

Issue 2864833002: Tapping handle shouldn't select misspelled word (Closed)
Patch Set: Mac test Created 3 years, 7 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
Index: third_party/WebKit/Source/web/WebViewImpl.cpp
diff --git a/third_party/WebKit/Source/web/WebViewImpl.cpp b/third_party/WebKit/Source/web/WebViewImpl.cpp
index 753c293cb260a97f1339e69ef3709a3419527fa8..99b4b0965c7a7cfaa1ffc5a8f022df9a6bf194ce 100644
--- a/third_party/WebKit/Source/web/WebViewImpl.cpp
+++ b/third_party/WebKit/Source/web/WebViewImpl.cpp
@@ -134,6 +134,7 @@
#include "public/platform/WebFloatPoint.h"
#include "public/platform/WebGestureCurve.h"
#include "public/platform/WebImage.h"
+#include "public/platform/WebInputEvent.h"
#include "public/platform/WebLayerTreeView.h"
#include "public/platform/WebTextInputInfo.h"
#include "public/platform/WebURLRequest.h"
@@ -150,6 +151,7 @@
#include "public/web/WebInputElement.h"
#include "public/web/WebMeaningfulLayout.h"
#include "public/web/WebMediaPlayerAction.h"
+#include "public/web/WebMenuSourceType.h"
#include "public/web/WebNode.h"
#include "public/web/WebPlugin.h"
#include "public/web/WebPluginAction.h"
@@ -3504,16 +3506,18 @@ void WebViewImpl::PerformCustomContextMenuAction(unsigned action) {
page_->GetContextMenuController().ClearContextMenu();
}
-void WebViewImpl::ShowContextMenu() {
+void WebViewImpl::ShowContextMenu(WebMenuSourceType source_type) {
if (!GetPage())
return;
GetPage()->GetContextMenuController().ClearContextMenu();
{
ContextMenuAllowedScope scope;
- if (LocalFrame* focused_frame =
- ToLocalFrame(GetPage()->GetFocusController().FocusedOrMainFrame()))
- focused_frame->GetEventHandler().SendContextMenuEventForKey(nullptr);
+ if (LocalFrame* focused_frame = ToLocalFrame(
+ GetPage()->GetFocusController().FocusedOrMainFrame())) {
+ focused_frame->GetEventHandler().SendContextMenuEventForKey(nullptr,
+ source_type);
+ }
}
}

Powered by Google App Engine
This is Rietveld 408576698