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

Side by Side Diff: content/renderer/npapi/webplugin_delegate_proxy.cc

Issue 326403002: Merge ViewHostMsg_TextInputTypeChanged and ViewHostMsg_TextInputStateChanged into one. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fixed. Created 6 years, 6 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 unified diff | Download patch
« no previous file with comments | « content/common/view_messages.h ('k') | content/renderer/render_frame_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 899 matching lines...) Expand 10 before | Expand all | Expand 10 after
910 910
911 modal_loop_pump_messages_event_.reset( 911 modal_loop_pump_messages_event_.reset(
912 new base::WaitableEvent(modal_loop_pump_messages_event)); 912 new base::WaitableEvent(modal_loop_pump_messages_event));
913 } 913 }
914 914
915 void WebPluginDelegateProxy::OnNotifyIMEStatus(int input_type, 915 void WebPluginDelegateProxy::OnNotifyIMEStatus(int input_type,
916 const gfx::Rect& caret_rect) { 916 const gfx::Rect& caret_rect) {
917 if (!render_view_) 917 if (!render_view_)
918 return; 918 return;
919 919
920 render_view_->Send(new ViewHostMsg_TextInputTypeChanged( 920 ViewHostMsg_TextInputState_Params p;
921 render_view_->routing_id(), 921 p.type = static_cast<ui::TextInputType>(input_type);
922 static_cast<ui::TextInputType>(input_type), 922 p.mode = ui::TEXT_INPUT_MODE_DEFAULT;
923 ui::TEXT_INPUT_MODE_DEFAULT, 923 p.can_compose_inline = true;
924 true)); 924
925 render_view_->Send(new ViewHostMsg_TextInputStateChanged(
926 render_view_->routing_id(), p));
925 927
926 ViewHostMsg_SelectionBounds_Params bounds_params; 928 ViewHostMsg_SelectionBounds_Params bounds_params;
927 bounds_params.anchor_rect = bounds_params.focus_rect = caret_rect; 929 bounds_params.anchor_rect = bounds_params.focus_rect = caret_rect;
928 bounds_params.anchor_dir = bounds_params.focus_dir = 930 bounds_params.anchor_dir = bounds_params.focus_dir =
929 blink::WebTextDirectionLeftToRight; 931 blink::WebTextDirectionLeftToRight;
930 bounds_params.is_anchor_first = true; 932 bounds_params.is_anchor_first = true;
931 render_view_->Send(new ViewHostMsg_SelectionBoundsChanged( 933 render_view_->Send(new ViewHostMsg_SelectionBoundsChanged(
932 render_view_->routing_id(), 934 render_view_->routing_id(),
933 bounds_params)); 935 bounds_params));
934 } 936 }
(...skipping 299 matching lines...) Expand 10 before | Expand all | Expand 10 after
1234 1236
1235 plugin_->URLRedirectResponse(allow, resource_id); 1237 plugin_->URLRedirectResponse(allow, resource_id);
1236 } 1238 }
1237 1239
1238 void WebPluginDelegateProxy::OnCheckIfRunInsecureContent(const GURL& url, 1240 void WebPluginDelegateProxy::OnCheckIfRunInsecureContent(const GURL& url,
1239 bool* result) { 1241 bool* result) {
1240 *result = plugin_->CheckIfRunInsecureContent(url); 1242 *result = plugin_->CheckIfRunInsecureContent(url);
1241 } 1243 }
1242 1244
1243 } // namespace content 1245 } // namespace content
OLDNEW
« no previous file with comments | « content/common/view_messages.h ('k') | content/renderer/render_frame_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698