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 1571 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1582 IPC_MESSAGE_HANDLER(FrameMsg_SetFrameOwnerProperties, | 1582 IPC_MESSAGE_HANDLER(FrameMsg_SetFrameOwnerProperties, |
1583 OnSetFrameOwnerProperties) | 1583 OnSetFrameOwnerProperties) |
1584 IPC_MESSAGE_HANDLER(FrameMsg_AdvanceFocus, OnAdvanceFocus) | 1584 IPC_MESSAGE_HANDLER(FrameMsg_AdvanceFocus, OnAdvanceFocus) |
1585 IPC_MESSAGE_HANDLER(FrameMsg_SetFocusedFrame, OnSetFocusedFrame) | 1585 IPC_MESSAGE_HANDLER(FrameMsg_SetFocusedFrame, OnSetFocusedFrame) |
1586 IPC_MESSAGE_HANDLER(FrameMsg_SetTextTrackSettings, | 1586 IPC_MESSAGE_HANDLER(FrameMsg_SetTextTrackSettings, |
1587 OnTextTrackSettingsChanged) | 1587 OnTextTrackSettingsChanged) |
1588 IPC_MESSAGE_HANDLER(FrameMsg_PostMessageEvent, OnPostMessageEvent) | 1588 IPC_MESSAGE_HANDLER(FrameMsg_PostMessageEvent, OnPostMessageEvent) |
1589 IPC_MESSAGE_HANDLER(FrameMsg_FailedNavigation, OnFailedNavigation) | 1589 IPC_MESSAGE_HANDLER(FrameMsg_FailedNavigation, OnFailedNavigation) |
1590 IPC_MESSAGE_HANDLER(FrameMsg_ReportContentSecurityPolicyViolation, | 1590 IPC_MESSAGE_HANDLER(FrameMsg_ReportContentSecurityPolicyViolation, |
1591 OnReportContentSecurityPolicyViolation) | 1591 OnReportContentSecurityPolicyViolation) |
1592 IPC_MESSAGE_HANDLER(FrameMsg_DroppedNavigation, OnDroppedNavigation) | |
1592 IPC_MESSAGE_HANDLER(FrameMsg_GetSavableResourceLinks, | 1593 IPC_MESSAGE_HANDLER(FrameMsg_GetSavableResourceLinks, |
1593 OnGetSavableResourceLinks) | 1594 OnGetSavableResourceLinks) |
1594 IPC_MESSAGE_HANDLER(FrameMsg_GetSerializedHtmlWithLocalLinks, | 1595 IPC_MESSAGE_HANDLER(FrameMsg_GetSerializedHtmlWithLocalLinks, |
1595 OnGetSerializedHtmlWithLocalLinks) | 1596 OnGetSerializedHtmlWithLocalLinks) |
1596 IPC_MESSAGE_HANDLER(FrameMsg_SerializeAsMHTML, OnSerializeAsMHTML) | 1597 IPC_MESSAGE_HANDLER(FrameMsg_SerializeAsMHTML, OnSerializeAsMHTML) |
1597 IPC_MESSAGE_HANDLER(FrameMsg_Find, OnFind) | 1598 IPC_MESSAGE_HANDLER(FrameMsg_Find, OnFind) |
1598 IPC_MESSAGE_HANDLER(FrameMsg_ClearActiveFindMatch, OnClearActiveFindMatch) | 1599 IPC_MESSAGE_HANDLER(FrameMsg_ClearActiveFindMatch, OnClearActiveFindMatch) |
1599 IPC_MESSAGE_HANDLER(FrameMsg_StopFinding, OnStopFinding) | 1600 IPC_MESSAGE_HANDLER(FrameMsg_StopFinding, OnStopFinding) |
1600 IPC_MESSAGE_HANDLER(FrameMsg_EnableViewSourceMode, OnEnableViewSourceMode) | 1601 IPC_MESSAGE_HANDLER(FrameMsg_EnableViewSourceMode, OnEnableViewSourceMode) |
1601 IPC_MESSAGE_HANDLER(FrameMsg_SuppressFurtherDialogs, | 1602 IPC_MESSAGE_HANDLER(FrameMsg_SuppressFurtherDialogs, |
(...skipping 3703 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
5305 | 5306 |
5306 browser_side_navigation_pending_ = false; | 5307 browser_side_navigation_pending_ = false; |
5307 } | 5308 } |
5308 | 5309 |
5309 void RenderFrameImpl::OnReportContentSecurityPolicyViolation( | 5310 void RenderFrameImpl::OnReportContentSecurityPolicyViolation( |
5310 const content::CSPViolationParams& violation_params) { | 5311 const content::CSPViolationParams& violation_params) { |
5311 frame_->reportContentSecurityPolicyViolation( | 5312 frame_->reportContentSecurityPolicyViolation( |
5312 BuildWebContentSecurityPolicyViolation(violation_params)); | 5313 BuildWebContentSecurityPolicyViolation(violation_params)); |
5313 } | 5314 } |
5314 | 5315 |
5316 void RenderFrameImpl::OnDroppedNavigation() { | |
Charlie Reis
2017/03/23 16:52:53
Maybe we should put this alongside OnStop() to mak
| |
5317 browser_side_navigation_pending_ = false; | |
5318 frame_->clientDroppedNavigation(); | |
5319 } | |
5320 | |
5315 WebNavigationPolicy RenderFrameImpl::decidePolicyForNavigation( | 5321 WebNavigationPolicy RenderFrameImpl::decidePolicyForNavigation( |
5316 const NavigationPolicyInfo& info) { | 5322 const NavigationPolicyInfo& info) { |
5317 // A content initiated navigation may have originated from a link-click, | 5323 // A content initiated navigation may have originated from a link-click, |
5318 // script, drag-n-drop operation, etc. | 5324 // script, drag-n-drop operation, etc. |
5319 // info.extraData is only non-null if this is a redirect. Use the extraData | 5325 // info.extraData is only non-null if this is a redirect. Use the extraData |
5320 // initiation information for redirects, and check pending_navigation_params_ | 5326 // initiation information for redirects, and check pending_navigation_params_ |
5321 // otherwise. | 5327 // otherwise. |
5322 bool is_content_initiated = | 5328 bool is_content_initiated = |
5323 info.extraData | 5329 info.extraData |
5324 ? static_cast<DocumentState*>(info.extraData) | 5330 ? static_cast<DocumentState*>(info.extraData) |
(...skipping 1645 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
6970 policy(info.defaultPolicy), | 6976 policy(info.defaultPolicy), |
6971 replaces_current_history_item(info.replacesCurrentHistoryItem), | 6977 replaces_current_history_item(info.replacesCurrentHistoryItem), |
6972 history_navigation_in_new_child_frame( | 6978 history_navigation_in_new_child_frame( |
6973 info.isHistoryNavigationInNewChildFrame), | 6979 info.isHistoryNavigationInNewChildFrame), |
6974 client_redirect(info.isClientRedirect), | 6980 client_redirect(info.isClientRedirect), |
6975 cache_disabled(info.isCacheDisabled), | 6981 cache_disabled(info.isCacheDisabled), |
6976 form(info.form), | 6982 form(info.form), |
6977 source_location(info.sourceLocation) {} | 6983 source_location(info.sourceLocation) {} |
6978 | 6984 |
6979 } // namespace content | 6985 } // namespace content |
OLD | NEW |