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 169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
180 #include "services/service_manager/public/cpp/connector.h" | 180 #include "services/service_manager/public/cpp/connector.h" |
181 #include "services/service_manager/public/cpp/interface_provider.h" | 181 #include "services/service_manager/public/cpp/interface_provider.h" |
182 #include "services/service_manager/public/cpp/interface_registry.h" | 182 #include "services/service_manager/public/cpp/interface_registry.h" |
183 #include "services/ui/public/cpp/gpu/context_provider_command_buffer.h" | 183 #include "services/ui/public/cpp/gpu/context_provider_command_buffer.h" |
184 #include "storage/common/data_element.h" | 184 #include "storage/common/data_element.h" |
185 #include "third_party/WebKit/public/platform/FilePathConversion.h" | 185 #include "third_party/WebKit/public/platform/FilePathConversion.h" |
186 #include "third_party/WebKit/public/platform/InterfaceProvider.h" | 186 #include "third_party/WebKit/public/platform/InterfaceProvider.h" |
187 #include "third_party/WebKit/public/platform/URLConversion.h" | 187 #include "third_party/WebKit/public/platform/URLConversion.h" |
188 #include "third_party/WebKit/public/platform/WebCachePolicy.h" | 188 #include "third_party/WebKit/public/platform/WebCachePolicy.h" |
189 #include "third_party/WebKit/public/platform/WebData.h" | 189 #include "third_party/WebKit/public/platform/WebData.h" |
| 190 #include "third_party/WebKit/public/platform/WebFocusType.h" |
190 #include "third_party/WebKit/public/platform/WebKeyboardEvent.h" | 191 #include "third_party/WebKit/public/platform/WebKeyboardEvent.h" |
191 #include "third_party/WebKit/public/platform/WebMediaPlayer.h" | 192 #include "third_party/WebKit/public/platform/WebMediaPlayer.h" |
192 #include "third_party/WebKit/public/platform/WebMediaPlayerSource.h" | 193 #include "third_party/WebKit/public/platform/WebMediaPlayerSource.h" |
193 #include "third_party/WebKit/public/platform/WebPoint.h" | 194 #include "third_party/WebKit/public/platform/WebPoint.h" |
194 #include "third_party/WebKit/public/platform/WebSecurityOrigin.h" | 195 #include "third_party/WebKit/public/platform/WebSecurityOrigin.h" |
195 #include "third_party/WebKit/public/platform/WebStorageQuotaCallbacks.h" | 196 #include "third_party/WebKit/public/platform/WebStorageQuotaCallbacks.h" |
196 #include "third_party/WebKit/public/platform/WebString.h" | 197 #include "third_party/WebKit/public/platform/WebString.h" |
197 #include "third_party/WebKit/public/platform/WebURL.h" | 198 #include "third_party/WebKit/public/platform/WebURL.h" |
198 #include "third_party/WebKit/public/platform/WebURLError.h" | 199 #include "third_party/WebKit/public/platform/WebURLError.h" |
199 #include "third_party/WebKit/public/platform/WebURLResponse.h" | 200 #include "third_party/WebKit/public/platform/WebURLResponse.h" |
(...skipping 1403 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1603 OnSetAccessibilityMode) | 1604 OnSetAccessibilityMode) |
1604 IPC_MESSAGE_HANDLER(AccessibilityMsg_SnapshotTree, | 1605 IPC_MESSAGE_HANDLER(AccessibilityMsg_SnapshotTree, |
1605 OnSnapshotAccessibilityTree) | 1606 OnSnapshotAccessibilityTree) |
1606 IPC_MESSAGE_HANDLER(FrameMsg_ExtractSmartClipData, OnExtractSmartClipData) | 1607 IPC_MESSAGE_HANDLER(FrameMsg_ExtractSmartClipData, OnExtractSmartClipData) |
1607 IPC_MESSAGE_HANDLER(FrameMsg_UpdateOpener, OnUpdateOpener) | 1608 IPC_MESSAGE_HANDLER(FrameMsg_UpdateOpener, OnUpdateOpener) |
1608 IPC_MESSAGE_HANDLER(FrameMsg_CommitNavigation, OnCommitNavigation) | 1609 IPC_MESSAGE_HANDLER(FrameMsg_CommitNavigation, OnCommitNavigation) |
1609 IPC_MESSAGE_HANDLER(FrameMsg_DidUpdateFramePolicy, OnDidUpdateFramePolicy) | 1610 IPC_MESSAGE_HANDLER(FrameMsg_DidUpdateFramePolicy, OnDidUpdateFramePolicy) |
1610 IPC_MESSAGE_HANDLER(FrameMsg_SetFrameOwnerProperties, | 1611 IPC_MESSAGE_HANDLER(FrameMsg_SetFrameOwnerProperties, |
1611 OnSetFrameOwnerProperties) | 1612 OnSetFrameOwnerProperties) |
1612 IPC_MESSAGE_HANDLER(FrameMsg_AdvanceFocus, OnAdvanceFocus) | 1613 IPC_MESSAGE_HANDLER(FrameMsg_AdvanceFocus, OnAdvanceFocus) |
| 1614 IPC_MESSAGE_HANDLER(FrameMsg_AdvanceFocusInForm, OnAdvanceFocusInForm) |
1613 IPC_MESSAGE_HANDLER(FrameMsg_SetFocusedFrame, OnSetFocusedFrame) | 1615 IPC_MESSAGE_HANDLER(FrameMsg_SetFocusedFrame, OnSetFocusedFrame) |
1614 IPC_MESSAGE_HANDLER(FrameMsg_SetTextTrackSettings, | 1616 IPC_MESSAGE_HANDLER(FrameMsg_SetTextTrackSettings, |
1615 OnTextTrackSettingsChanged) | 1617 OnTextTrackSettingsChanged) |
1616 IPC_MESSAGE_HANDLER(FrameMsg_PostMessageEvent, OnPostMessageEvent) | 1618 IPC_MESSAGE_HANDLER(FrameMsg_PostMessageEvent, OnPostMessageEvent) |
1617 IPC_MESSAGE_HANDLER(FrameMsg_FailedNavigation, OnFailedNavigation) | 1619 IPC_MESSAGE_HANDLER(FrameMsg_FailedNavigation, OnFailedNavigation) |
1618 IPC_MESSAGE_HANDLER(FrameMsg_ReportContentSecurityPolicyViolation, | 1620 IPC_MESSAGE_HANDLER(FrameMsg_ReportContentSecurityPolicyViolation, |
1619 OnReportContentSecurityPolicyViolation) | 1621 OnReportContentSecurityPolicyViolation) |
1620 IPC_MESSAGE_HANDLER(FrameMsg_GetSavableResourceLinks, | 1622 IPC_MESSAGE_HANDLER(FrameMsg_GetSavableResourceLinks, |
1621 OnGetSavableResourceLinks) | 1623 OnGetSavableResourceLinks) |
1622 IPC_MESSAGE_HANDLER(FrameMsg_GetSerializedHtmlWithLocalLinks, | 1624 IPC_MESSAGE_HANDLER(FrameMsg_GetSerializedHtmlWithLocalLinks, |
(...skipping 609 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2232 int32_t source_routing_id) { | 2234 int32_t source_routing_id) { |
2233 RenderFrameProxy* source_frame = | 2235 RenderFrameProxy* source_frame = |
2234 RenderFrameProxy::FromRoutingID(source_routing_id); | 2236 RenderFrameProxy::FromRoutingID(source_routing_id); |
2235 if (!source_frame) | 2237 if (!source_frame) |
2236 return; | 2238 return; |
2237 | 2239 |
2238 render_view_->webview()->AdvanceFocusAcrossFrames( | 2240 render_view_->webview()->AdvanceFocusAcrossFrames( |
2239 type, source_frame->web_frame(), frame_); | 2241 type, source_frame->web_frame(), frame_); |
2240 } | 2242 } |
2241 | 2243 |
| 2244 void RenderFrameImpl::OnAdvanceFocusInForm(bool forward) { |
| 2245 if (render_view_->webview()->FocusedFrame() != frame_) |
| 2246 return; |
| 2247 frame_->AdvanceFocusInForm(forward ? blink::kWebFocusTypeForward |
| 2248 : blink::kWebFocusTypeBackward); |
| 2249 } |
| 2250 |
2242 void RenderFrameImpl::OnSetFocusedFrame() { | 2251 void RenderFrameImpl::OnSetFocusedFrame() { |
2243 // This uses focusDocumentView rather than setFocusedFrame so that focus/blur | 2252 // This uses focusDocumentView rather than setFocusedFrame so that focus/blur |
2244 // events are properly dispatched on any currently focused elements. | 2253 // events are properly dispatched on any currently focused elements. |
2245 render_view_->webview()->FocusDocumentView(frame_); | 2254 render_view_->webview()->FocusDocumentView(frame_); |
2246 } | 2255 } |
2247 | 2256 |
2248 void RenderFrameImpl::OnTextTrackSettingsChanged( | 2257 void RenderFrameImpl::OnTextTrackSettingsChanged( |
2249 const FrameMsg_TextTrackSettings_Params& params) { | 2258 const FrameMsg_TextTrackSettings_Params& params) { |
2250 DCHECK(!frame_->Parent()); | 2259 DCHECK(!frame_->Parent()); |
2251 if (!render_view_->webview()) | 2260 if (!render_view_->webview()) |
(...skipping 4798 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7050 policy(info.default_policy), | 7059 policy(info.default_policy), |
7051 replaces_current_history_item(info.replaces_current_history_item), | 7060 replaces_current_history_item(info.replaces_current_history_item), |
7052 history_navigation_in_new_child_frame( | 7061 history_navigation_in_new_child_frame( |
7053 info.is_history_navigation_in_new_child_frame), | 7062 info.is_history_navigation_in_new_child_frame), |
7054 client_redirect(info.is_client_redirect), | 7063 client_redirect(info.is_client_redirect), |
7055 cache_disabled(info.is_cache_disabled), | 7064 cache_disabled(info.is_cache_disabled), |
7056 form(info.form), | 7065 form(info.form), |
7057 source_location(info.source_location) {} | 7066 source_location(info.source_location) {} |
7058 | 7067 |
7059 } // namespace content | 7068 } // namespace content |
OLD | NEW |