OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/browser/frame_host/cross_process_frame_connector.h" | 5 #include "content/browser/frame_host/cross_process_frame_connector.h" |
6 | 6 |
7 #include "cc/surfaces/surface.h" | 7 #include "cc/surfaces/surface.h" |
8 #include "cc/surfaces/surface_manager.h" | 8 #include "cc/surfaces/surface_manager.h" |
9 #include "content/browser/compositor/surface_utils.h" | 9 #include "content/browser/compositor/surface_utils.h" |
10 #include "content/browser/frame_host/frame_tree.h" | 10 #include "content/browser/frame_host/frame_tree.h" |
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
163 return root_view->HasFocus(); | 163 return root_view->HasFocus(); |
164 return false; | 164 return false; |
165 } | 165 } |
166 | 166 |
167 void CrossProcessFrameConnector::FocusRootView() { | 167 void CrossProcessFrameConnector::FocusRootView() { |
168 RenderWidgetHostViewBase* root_view = GetRootRenderWidgetHostView(); | 168 RenderWidgetHostViewBase* root_view = GetRootRenderWidgetHostView(); |
169 if (root_view) | 169 if (root_view) |
170 root_view->Focus(); | 170 root_view->Focus(); |
171 } | 171 } |
172 | 172 |
| 173 void CrossProcessFrameConnector::NotifyRootViewOfTextInputStateChanged() { |
| 174 RenderWidgetHostViewBase* root_view = GetRootRenderWidgetHostView(); |
| 175 if (root_view) |
| 176 root_view->UpdateTextInputState(); |
| 177 } |
| 178 |
173 void CrossProcessFrameConnector::OnForwardInputEvent( | 179 void CrossProcessFrameConnector::OnForwardInputEvent( |
174 const blink::WebInputEvent* event) { | 180 const blink::WebInputEvent* event) { |
175 if (!view_) | 181 if (!view_) |
176 return; | 182 return; |
177 | 183 |
178 RenderFrameHostManager* manager = | 184 RenderFrameHostManager* manager = |
179 frame_proxy_in_parent_renderer_->frame_tree_node()->render_manager(); | 185 frame_proxy_in_parent_renderer_->frame_tree_node()->render_manager(); |
180 RenderWidgetHostImpl* parent_widget = | 186 RenderWidgetHostImpl* parent_widget = |
181 manager->ForInnerDelegate() | 187 manager->ForInnerDelegate() |
182 ? manager->GetOuterRenderWidgetHostForKeyboardInput() | 188 ? manager->GetOuterRenderWidgetHostForKeyboardInput() |
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
284 | 290 |
285 if (parent) { | 291 if (parent) { |
286 return static_cast<RenderWidgetHostViewBase*>( | 292 return static_cast<RenderWidgetHostViewBase*>( |
287 parent->current_frame_host()->GetView()); | 293 parent->current_frame_host()->GetView()); |
288 } | 294 } |
289 | 295 |
290 return nullptr; | 296 return nullptr; |
291 } | 297 } |
292 | 298 |
293 } // namespace content | 299 } // namespace content |
OLD | NEW |