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 <algorithm> | 7 #include <algorithm> |
8 #include <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
10 #include <utility> | 10 #include <utility> |
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
169 #include "ppapi/features/features.h" | 169 #include "ppapi/features/features.h" |
170 #include "services/service_manager/public/cpp/connector.h" | 170 #include "services/service_manager/public/cpp/connector.h" |
171 #include "services/service_manager/public/cpp/interface_provider.h" | 171 #include "services/service_manager/public/cpp/interface_provider.h" |
172 #include "services/ui/public/cpp/gpu/context_provider_command_buffer.h" | 172 #include "services/ui/public/cpp/gpu/context_provider_command_buffer.h" |
173 #include "storage/common/data_element.h" | 173 #include "storage/common/data_element.h" |
174 #include "third_party/WebKit/public/platform/FilePathConversion.h" | 174 #include "third_party/WebKit/public/platform/FilePathConversion.h" |
175 #include "third_party/WebKit/public/platform/InterfaceProvider.h" | 175 #include "third_party/WebKit/public/platform/InterfaceProvider.h" |
176 #include "third_party/WebKit/public/platform/URLConversion.h" | 176 #include "third_party/WebKit/public/platform/URLConversion.h" |
177 #include "third_party/WebKit/public/platform/WebCachePolicy.h" | 177 #include "third_party/WebKit/public/platform/WebCachePolicy.h" |
178 #include "third_party/WebKit/public/platform/WebData.h" | 178 #include "third_party/WebKit/public/platform/WebData.h" |
| 179 #include "third_party/WebKit/public/platform/WebFocusType.h" |
179 #include "third_party/WebKit/public/platform/WebKeyboardEvent.h" | 180 #include "third_party/WebKit/public/platform/WebKeyboardEvent.h" |
180 #include "third_party/WebKit/public/platform/WebMediaPlayer.h" | 181 #include "third_party/WebKit/public/platform/WebMediaPlayer.h" |
181 #include "third_party/WebKit/public/platform/WebMediaPlayerSource.h" | 182 #include "third_party/WebKit/public/platform/WebMediaPlayerSource.h" |
182 #include "third_party/WebKit/public/platform/WebPoint.h" | 183 #include "third_party/WebKit/public/platform/WebPoint.h" |
183 #include "third_party/WebKit/public/platform/WebSecurityOrigin.h" | 184 #include "third_party/WebKit/public/platform/WebSecurityOrigin.h" |
184 #include "third_party/WebKit/public/platform/WebStorageQuotaCallbacks.h" | 185 #include "third_party/WebKit/public/platform/WebStorageQuotaCallbacks.h" |
185 #include "third_party/WebKit/public/platform/WebString.h" | 186 #include "third_party/WebKit/public/platform/WebString.h" |
186 #include "third_party/WebKit/public/platform/WebURL.h" | 187 #include "third_party/WebKit/public/platform/WebURL.h" |
187 #include "third_party/WebKit/public/platform/WebURLError.h" | 188 #include "third_party/WebKit/public/platform/WebURLError.h" |
188 #include "third_party/WebKit/public/platform/WebURLResponse.h" | 189 #include "third_party/WebKit/public/platform/WebURLResponse.h" |
(...skipping 1448 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1637 OnSetAccessibilityMode) | 1638 OnSetAccessibilityMode) |
1638 IPC_MESSAGE_HANDLER(AccessibilityMsg_SnapshotTree, | 1639 IPC_MESSAGE_HANDLER(AccessibilityMsg_SnapshotTree, |
1639 OnSnapshotAccessibilityTree) | 1640 OnSnapshotAccessibilityTree) |
1640 IPC_MESSAGE_HANDLER(FrameMsg_ExtractSmartClipData, OnExtractSmartClipData) | 1641 IPC_MESSAGE_HANDLER(FrameMsg_ExtractSmartClipData, OnExtractSmartClipData) |
1641 IPC_MESSAGE_HANDLER(FrameMsg_UpdateOpener, OnUpdateOpener) | 1642 IPC_MESSAGE_HANDLER(FrameMsg_UpdateOpener, OnUpdateOpener) |
1642 IPC_MESSAGE_HANDLER(FrameMsg_CommitNavigation, OnCommitNavigation) | 1643 IPC_MESSAGE_HANDLER(FrameMsg_CommitNavigation, OnCommitNavigation) |
1643 IPC_MESSAGE_HANDLER(FrameMsg_DidUpdateFramePolicy, OnDidUpdateFramePolicy) | 1644 IPC_MESSAGE_HANDLER(FrameMsg_DidUpdateFramePolicy, OnDidUpdateFramePolicy) |
1644 IPC_MESSAGE_HANDLER(FrameMsg_SetFrameOwnerProperties, | 1645 IPC_MESSAGE_HANDLER(FrameMsg_SetFrameOwnerProperties, |
1645 OnSetFrameOwnerProperties) | 1646 OnSetFrameOwnerProperties) |
1646 IPC_MESSAGE_HANDLER(FrameMsg_AdvanceFocus, OnAdvanceFocus) | 1647 IPC_MESSAGE_HANDLER(FrameMsg_AdvanceFocus, OnAdvanceFocus) |
| 1648 IPC_MESSAGE_HANDLER(FrameMsg_AdvanceFocusInForm, OnAdvanceFocusInForm) |
1647 IPC_MESSAGE_HANDLER(FrameMsg_SetFocusedFrame, OnSetFocusedFrame) | 1649 IPC_MESSAGE_HANDLER(FrameMsg_SetFocusedFrame, OnSetFocusedFrame) |
1648 IPC_MESSAGE_HANDLER(FrameMsg_SetTextTrackSettings, | 1650 IPC_MESSAGE_HANDLER(FrameMsg_SetTextTrackSettings, |
1649 OnTextTrackSettingsChanged) | 1651 OnTextTrackSettingsChanged) |
1650 IPC_MESSAGE_HANDLER(FrameMsg_PostMessageEvent, OnPostMessageEvent) | 1652 IPC_MESSAGE_HANDLER(FrameMsg_PostMessageEvent, OnPostMessageEvent) |
1651 IPC_MESSAGE_HANDLER(FrameMsg_FailedNavigation, OnFailedNavigation) | 1653 IPC_MESSAGE_HANDLER(FrameMsg_FailedNavigation, OnFailedNavigation) |
1652 IPC_MESSAGE_HANDLER(FrameMsg_ReportContentSecurityPolicyViolation, | 1654 IPC_MESSAGE_HANDLER(FrameMsg_ReportContentSecurityPolicyViolation, |
1653 OnReportContentSecurityPolicyViolation) | 1655 OnReportContentSecurityPolicyViolation) |
1654 IPC_MESSAGE_HANDLER(FrameMsg_GetSavableResourceLinks, | 1656 IPC_MESSAGE_HANDLER(FrameMsg_GetSavableResourceLinks, |
1655 OnGetSavableResourceLinks) | 1657 OnGetSavableResourceLinks) |
1656 IPC_MESSAGE_HANDLER(FrameMsg_GetSerializedHtmlWithLocalLinks, | 1658 IPC_MESSAGE_HANDLER(FrameMsg_GetSerializedHtmlWithLocalLinks, |
(...skipping 610 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2267 if (!source_frame) { | 2269 if (!source_frame) { |
2268 render_view_->webview()->SetInitialFocus(type == | 2270 render_view_->webview()->SetInitialFocus(type == |
2269 blink::kWebFocusTypeBackward); | 2271 blink::kWebFocusTypeBackward); |
2270 return; | 2272 return; |
2271 } | 2273 } |
2272 | 2274 |
2273 render_view_->webview()->AdvanceFocusAcrossFrames( | 2275 render_view_->webview()->AdvanceFocusAcrossFrames( |
2274 type, source_frame->web_frame(), frame_); | 2276 type, source_frame->web_frame(), frame_); |
2275 } | 2277 } |
2276 | 2278 |
| 2279 void RenderFrameImpl::OnAdvanceFocusInForm(blink::WebFocusType focus_type) { |
| 2280 if (render_view_->webview()->FocusedFrame() != frame_) |
| 2281 return; |
| 2282 frame_->AdvanceFocusInForm(focus_type); |
| 2283 } |
| 2284 |
2277 void RenderFrameImpl::OnSetFocusedFrame() { | 2285 void RenderFrameImpl::OnSetFocusedFrame() { |
2278 // This uses focusDocumentView rather than setFocusedFrame so that focus/blur | 2286 // This uses focusDocumentView rather than setFocusedFrame so that focus/blur |
2279 // events are properly dispatched on any currently focused elements. | 2287 // events are properly dispatched on any currently focused elements. |
2280 render_view_->webview()->FocusDocumentView(frame_); | 2288 render_view_->webview()->FocusDocumentView(frame_); |
2281 } | 2289 } |
2282 | 2290 |
2283 void RenderFrameImpl::OnTextTrackSettingsChanged( | 2291 void RenderFrameImpl::OnTextTrackSettingsChanged( |
2284 const FrameMsg_TextTrackSettings_Params& params) { | 2292 const FrameMsg_TextTrackSettings_Params& params) { |
2285 DCHECK(!frame_->Parent()); | 2293 DCHECK(!frame_->Parent()); |
2286 if (!render_view_->webview()) | 2294 if (!render_view_->webview()) |
(...skipping 4598 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6885 replaces_current_history_item(info.replaces_current_history_item), | 6893 replaces_current_history_item(info.replaces_current_history_item), |
6886 history_navigation_in_new_child_frame( | 6894 history_navigation_in_new_child_frame( |
6887 info.is_history_navigation_in_new_child_frame), | 6895 info.is_history_navigation_in_new_child_frame), |
6888 client_redirect(info.is_client_redirect), | 6896 client_redirect(info.is_client_redirect), |
6889 triggering_event_info(info.triggering_event_info), | 6897 triggering_event_info(info.triggering_event_info), |
6890 cache_disabled(info.is_cache_disabled), | 6898 cache_disabled(info.is_cache_disabled), |
6891 form(info.form), | 6899 form(info.form), |
6892 source_location(info.source_location) {} | 6900 source_location(info.source_location) {} |
6893 | 6901 |
6894 } // namespace content | 6902 } // namespace content |
OLD | NEW |