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

Unified Diff: content/browser/renderer_host/render_widget_host_impl.cc

Issue 2785853002: Selection Action mode triggered like a context menu (Closed)
Patch Set: Fixing rebase bug Created 3 years, 8 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: content/browser/renderer_host/render_widget_host_impl.cc
diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc
index 146ec02c0448a754cb88cd661b333437cc69a164..7b90434049b6910e84bd079cad620865be0709dc 100644
--- a/content/browser/renderer_host/render_widget_host_impl.cc
+++ b/content/browser/renderer_host/render_widget_host_impl.cc
@@ -1316,9 +1316,11 @@ void RenderWidgetHostImpl::SetCursor(const WebCursor& cursor) {
view_->UpdateCursor(cursor);
}
-void RenderWidgetHostImpl::ShowContextMenuAtPoint(const gfx::Point& point) {
- Send(new ViewMsg_ShowContextMenu(
- GetRoutingID(), ui::MENU_SOURCE_MOUSE, point));
+void RenderWidgetHostImpl::ShowContextMenuAtPoint(const gfx::Point& point,
+ bool from_touch) {
+ const ui::MenuSourceType menu_source_type =
+ from_touch ? ui::MENU_SOURCE_TOUCH : ui::MENU_SOURCE_MOUSE;
+ Send(new ViewMsg_ShowContextMenu(GetRoutingID(), menu_source_type, point));
}
void RenderWidgetHostImpl::SendCursorVisibilityState(bool is_visible) {

Powered by Google App Engine
This is Rietveld 408576698