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 4754 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
4765 else | 4765 else |
4766 params.transition = ui::PAGE_TRANSITION_AUTO_SUBFRAME; | 4766 params.transition = ui::PAGE_TRANSITION_AUTO_SUBFRAME; |
4767 | 4767 |
4768 DCHECK(!navigation_state->request_params().should_clear_history_list); | 4768 DCHECK(!navigation_state->request_params().should_clear_history_list); |
4769 params.history_list_was_cleared = false; | 4769 params.history_list_was_cleared = false; |
4770 params.report_type = FrameMsg_UILoadMetricsReportType::NO_REPORT; | 4770 params.report_type = FrameMsg_UILoadMetricsReportType::NO_REPORT; |
4771 // Subframes should match the zoom level of the main frame. | 4771 // Subframes should match the zoom level of the main frame. |
4772 render_view_->SetZoomLevel(render_view_->page_zoom_level()); | 4772 render_view_->SetZoomLevel(render_view_->page_zoom_level()); |
4773 } | 4773 } |
4774 | 4774 |
4775 // Standard URLs must match the reported origin. | |
4776 // TODO(nasko): Remove this check once the root cause of | |
4777 // https://crbug.com/628677 is understood. | |
Charlie Reis
2016/07/15 17:49:18
Why not leave it in? :) Seems like it could help
nasko
2016/07/15 17:51:18
Sure :).
| |
4778 if (params.url.IsStandard()) | |
4779 CHECK(params.origin.IsSameOriginWith(url::Origin(params.url))); | |
4780 | |
4775 // This message needs to be sent before any of allowScripts(), | 4781 // This message needs to be sent before any of allowScripts(), |
4776 // allowImages(), allowPlugins() is called for the new page, so that when | 4782 // allowImages(), allowPlugins() is called for the new page, so that when |
4777 // these functions send a ViewHostMsg_ContentBlocked message, it arrives | 4783 // these functions send a ViewHostMsg_ContentBlocked message, it arrives |
4778 // after the FrameHostMsg_DidCommitProvisionalLoad message. | 4784 // after the FrameHostMsg_DidCommitProvisionalLoad message. |
4779 Send(new FrameHostMsg_DidCommitProvisionalLoad(routing_id_, params)); | 4785 Send(new FrameHostMsg_DidCommitProvisionalLoad(routing_id_, params)); |
4780 | 4786 |
4781 // If we end up reusing this WebRequest (for example, due to a #ref click), | 4787 // If we end up reusing this WebRequest (for example, due to a #ref click), |
4782 // we don't want the transition type to persist. Just clear it. | 4788 // we don't want the transition type to persist. Just clear it. |
4783 navigation_state->set_transition_type(ui::PAGE_TRANSITION_LINK); | 4789 navigation_state->set_transition_type(ui::PAGE_TRANSITION_LINK); |
4784 } | 4790 } |
(...skipping 1550 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
6335 // event target. Potentially a Pepper plugin will receive the event. | 6341 // event target. Potentially a Pepper plugin will receive the event. |
6336 // In order to tell whether a plugin gets the last mouse event and which it | 6342 // In order to tell whether a plugin gets the last mouse event and which it |
6337 // is, we set |pepper_last_mouse_event_target_| to null here. If a plugin gets | 6343 // is, we set |pepper_last_mouse_event_target_| to null here. If a plugin gets |
6338 // the event, it will notify us via DidReceiveMouseEvent() and set itself as | 6344 // the event, it will notify us via DidReceiveMouseEvent() and set itself as |
6339 // |pepper_last_mouse_event_target_|. | 6345 // |pepper_last_mouse_event_target_|. |
6340 pepper_last_mouse_event_target_ = nullptr; | 6346 pepper_last_mouse_event_target_ = nullptr; |
6341 #endif | 6347 #endif |
6342 } | 6348 } |
6343 | 6349 |
6344 } // namespace content | 6350 } // namespace content |
OLD | NEW |