OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "content/renderer/render_frame_impl.h" | 5 #include "content/renderer/render_frame_impl.h" |
6 | 6 |
7 #include <map> | 7 #include <map> |
8 #include <string> | 8 #include <string> |
9 #include <utility> | 9 #include <utility> |
10 #include <vector> | 10 #include <vector> |
(...skipping 4208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4219 else if (params.save_as) | 4219 else if (params.save_as) |
4220 ipc_params.mode = FileChooserParams::Save; | 4220 ipc_params.mode = FileChooserParams::Save; |
4221 else | 4221 else |
4222 ipc_params.mode = FileChooserParams::Open; | 4222 ipc_params.mode = FileChooserParams::Open; |
4223 ipc_params.title = params.title.Utf16(); | 4223 ipc_params.title = params.title.Utf16(); |
4224 ipc_params.accept_types.reserve(params.accept_types.size()); | 4224 ipc_params.accept_types.reserve(params.accept_types.size()); |
4225 for (const auto& type : params.accept_types) | 4225 for (const auto& type : params.accept_types) |
4226 ipc_params.accept_types.push_back(type.Utf16()); | 4226 ipc_params.accept_types.push_back(type.Utf16()); |
4227 ipc_params.need_local_path = params.need_local_path; | 4227 ipc_params.need_local_path = params.need_local_path; |
4228 #if defined(OS_ANDROID) | 4228 #if defined(OS_ANDROID) |
4229 ipc_params.capture = params.use_media_capture; | 4229 ipc_params.capture = params.capture.Utf16(); |
4230 #endif | 4230 #endif |
4231 ipc_params.requestor = params.requestor; | 4231 ipc_params.requestor = params.requestor; |
4232 | 4232 |
4233 return ScheduleFileChooser(ipc_params, chooser_completion); | 4233 return ScheduleFileChooser(ipc_params, chooser_completion); |
4234 } | 4234 } |
4235 | 4235 |
4236 void RenderFrameImpl::ShowContextMenu(const blink::WebContextMenuData& data) { | 4236 void RenderFrameImpl::ShowContextMenu(const blink::WebContextMenuData& data) { |
4237 ContextMenuParams params = ContextMenuParamsBuilder::Build(data); | 4237 ContextMenuParams params = ContextMenuParamsBuilder::Build(data); |
4238 blink::WebRect position_in_window(params.x, params.y, 0, 0); | 4238 blink::WebRect position_in_window(params.x, params.y, 0, 0); |
4239 GetRenderWidget()->ConvertViewportToWindow(&position_in_window); | 4239 GetRenderWidget()->ConvertViewportToWindow(&position_in_window); |
(...skipping 2760 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7000 policy(info.default_policy), | 7000 policy(info.default_policy), |
7001 replaces_current_history_item(info.replaces_current_history_item), | 7001 replaces_current_history_item(info.replaces_current_history_item), |
7002 history_navigation_in_new_child_frame( | 7002 history_navigation_in_new_child_frame( |
7003 info.is_history_navigation_in_new_child_frame), | 7003 info.is_history_navigation_in_new_child_frame), |
7004 client_redirect(info.is_client_redirect), | 7004 client_redirect(info.is_client_redirect), |
7005 cache_disabled(info.is_cache_disabled), | 7005 cache_disabled(info.is_cache_disabled), |
7006 form(info.form), | 7006 form(info.form), |
7007 source_location(info.source_location) {} | 7007 source_location(info.source_location) {} |
7008 | 7008 |
7009 } // namespace content | 7009 } // namespace content |
OLD | NEW |