OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/npapi/webplugin_delegate_proxy.h" | 5 #include "content/renderer/npapi/webplugin_delegate_proxy.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 | 8 |
9 #include "base/auto_reset.h" | 9 #include "base/auto_reset.h" |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 893 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
904 | 904 |
905 modal_loop_pump_messages_event_.reset( | 905 modal_loop_pump_messages_event_.reset( |
906 new base::WaitableEvent(modal_loop_pump_messages_event.Pass())); | 906 new base::WaitableEvent(modal_loop_pump_messages_event.Pass())); |
907 } | 907 } |
908 | 908 |
909 void WebPluginDelegateProxy::OnNotifyIMEStatus(int input_type, | 909 void WebPluginDelegateProxy::OnNotifyIMEStatus(int input_type, |
910 const gfx::Rect& caret_rect) { | 910 const gfx::Rect& caret_rect) { |
911 if (!render_view_) | 911 if (!render_view_) |
912 return; | 912 return; |
913 | 913 |
914 render_view_->Send(new ViewHostMsg_TextInputTypeChanged( | 914 ViewHostMsg_TextInputState_Params p; |
nasko
2015/07/29 17:41:07
nit: s/p/params/
Shu Chen
2015/07/30 00:47:22
Done.
| |
915 render_view_->routing_id(), | 915 p.type = static_cast<ui::TextInputType>(input_type); |
916 static_cast<ui::TextInputType>(input_type), | 916 p.mode = ui::TEXT_INPUT_MODE_DEFAULT; |
917 ui::TEXT_INPUT_MODE_DEFAULT, | 917 p.can_compose_inline = true; |
918 true, 0)); | 918 render_view_->Send(new ViewHostMsg_TextInputStateChanged( |
919 render_view_->routing_id(), p)); | |
919 | 920 |
920 ViewHostMsg_SelectionBounds_Params bounds_params; | 921 ViewHostMsg_SelectionBounds_Params bounds_params; |
921 bounds_params.anchor_rect = bounds_params.focus_rect = caret_rect; | 922 bounds_params.anchor_rect = bounds_params.focus_rect = caret_rect; |
922 bounds_params.anchor_dir = bounds_params.focus_dir = | 923 bounds_params.anchor_dir = bounds_params.focus_dir = |
923 blink::WebTextDirectionLeftToRight; | 924 blink::WebTextDirectionLeftToRight; |
924 bounds_params.is_anchor_first = true; | 925 bounds_params.is_anchor_first = true; |
925 render_view_->Send(new ViewHostMsg_SelectionBoundsChanged( | 926 render_view_->Send(new ViewHostMsg_SelectionBoundsChanged( |
926 render_view_->routing_id(), | 927 render_view_->routing_id(), |
927 bounds_params)); | 928 bounds_params)); |
928 } | 929 } |
(...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1229 | 1230 |
1230 plugin_->URLRedirectResponse(allow, resource_id); | 1231 plugin_->URLRedirectResponse(allow, resource_id); |
1231 } | 1232 } |
1232 | 1233 |
1233 void WebPluginDelegateProxy::OnCheckIfRunInsecureContent(const GURL& url, | 1234 void WebPluginDelegateProxy::OnCheckIfRunInsecureContent(const GURL& url, |
1234 bool* result) { | 1235 bool* result) { |
1235 *result = plugin_->CheckIfRunInsecureContent(url); | 1236 *result = plugin_->CheckIfRunInsecureContent(url); |
1236 } | 1237 } |
1237 | 1238 |
1238 } // namespace content | 1239 } // namespace content |
OLD | NEW |