| Index: content/browser/renderer_host/render_view_host_impl.cc
|
| diff --git a/content/browser/renderer_host/render_view_host_impl.cc b/content/browser/renderer_host/render_view_host_impl.cc
|
| index 2301a973f8d227eaddde3f892d5d19ccc22cb384..0a84ff3bbe5cfab21d29c94572a118d4b7ba189e 100644
|
| --- a/content/browser/renderer_host/render_view_host_impl.cc
|
| +++ b/content/browser/renderer_host/render_view_host_impl.cc
|
| @@ -1533,6 +1533,19 @@ void RenderViewHostImpl::DidCancelPopupMenu() {
|
| }
|
| #endif
|
|
|
| +#if defined(OS_ANDROID)
|
| +void RenderViewHostImpl::DidSelectPopupMenuItems(
|
| + const std::vector<int>& selected_indices) {
|
| + Send(new ViewMsg_SelectPopupMenuItems(GetRoutingID(), false,
|
| + selected_indices));
|
| +}
|
| +
|
| +void RenderViewHostImpl::DidCancelPopupMenu() {
|
| + Send(new ViewMsg_SelectPopupMenuItems(GetRoutingID(), true,
|
| + std::vector<int>()));
|
| +}
|
| +#endif
|
| +
|
| void RenderViewHostImpl::SendOrientationChangeEvent(int orientation) {
|
| Send(new ViewMsg_OrientationChangeEvent(GetRoutingID(), orientation));
|
| }
|
| @@ -1788,13 +1801,19 @@ void RenderViewHostImpl::OnCancelDesktopNotification(int notification_id) {
|
| GetProcess()->GetID(), GetRoutingID(), notification_id);
|
| }
|
|
|
| -#if defined(OS_MACOSX)
|
| +#if defined(OS_MACOSX) || defined(OS_ANDROID)
|
| void RenderViewHostImpl::OnMsgShowPopup(
|
| const ViewHostMsg_ShowPopup_Params& params) {
|
| - PopupMenuHelper popup_menu_helper(this);
|
| - popup_menu_helper.ShowPopupMenu(params.bounds, params.item_height,
|
| - params.item_font_size, params.selected_item,
|
| - params.popup_items, params.right_aligned);
|
| + RenderViewHostDelegateView* view = delegate_->GetDelegateView();
|
| + if (view) {
|
| + view->ShowPopupMenu(params.bounds,
|
| + params.item_height,
|
| + params.item_font_size,
|
| + params.selected_item,
|
| + params.popup_items,
|
| + params.right_aligned,
|
| + params.allow_multiple_selection);
|
| + }
|
| }
|
| #endif
|
|
|
|
|