| 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 4962 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4973 else | 4973 else |
| 4974 params.transition = ui::PAGE_TRANSITION_AUTO_SUBFRAME; | 4974 params.transition = ui::PAGE_TRANSITION_AUTO_SUBFRAME; |
| 4975 | 4975 |
| 4976 DCHECK(!navigation_state->request_params().should_clear_history_list); | 4976 DCHECK(!navigation_state->request_params().should_clear_history_list); |
| 4977 params.history_list_was_cleared = false; | 4977 params.history_list_was_cleared = false; |
| 4978 params.report_type = FrameMsg_UILoadMetricsReportType::NO_REPORT; | 4978 params.report_type = FrameMsg_UILoadMetricsReportType::NO_REPORT; |
| 4979 // Subframes should match the zoom level of the main frame. | 4979 // Subframes should match the zoom level of the main frame. |
| 4980 render_view_->SetZoomLevel(render_view_->page_zoom_level()); | 4980 render_view_->SetZoomLevel(render_view_->page_zoom_level()); |
| 4981 } | 4981 } |
| 4982 | 4982 |
| 4983 // Standard URLs must match the reported origin, when it is not unique. | 4983 // Standard URLs must match the reported origin, when it is not opaque. |
| 4984 // This check is very similar to RenderFrameHostImpl::CanCommitOrigin, but | 4984 // This check is very similar to RenderFrameHostImpl::CanCommitOrigin, but |
| 4985 // adapted to the renderer process side. | 4985 // adapted to the renderer process side. |
| 4986 if (!params.origin.unique() && params.url.IsStandard() && | 4986 if (!params.origin.opaque() && params.url.IsStandard() && |
| 4987 render_view_->GetWebkitPreferences().web_security_enabled) { | 4987 render_view_->GetWebkitPreferences().web_security_enabled) { |
| 4988 // Exclude file: URLs when settings allow them access any origin. | 4988 // Exclude file: URLs when settings allow them access any origin. |
| 4989 if (params.origin.scheme() != url::kFileScheme || | 4989 if (params.origin.scheme() != url::kFileScheme || |
| 4990 !render_view_->GetWebkitPreferences() | 4990 !render_view_->GetWebkitPreferences() |
| 4991 .allow_universal_access_from_file_urls) { | 4991 .allow_universal_access_from_file_urls) { |
| 4992 base::debug::SetCrashKeyValue("origin_mismatch_url", params.url.spec()); | 4992 base::debug::SetCrashKeyValue("origin_mismatch_url", params.url.spec()); |
| 4993 base::debug::SetCrashKeyValue("origin_mismatch_origin", | 4993 base::debug::SetCrashKeyValue("origin_mismatch_origin", |
| 4994 params.origin.Serialize()); | 4994 params.origin.Serialize()); |
| 4995 base::debug::SetCrashKeyValue("origin_mismatch_transition", | 4995 base::debug::SetCrashKeyValue("origin_mismatch_transition", |
| 4996 base::IntToString(params.transition)); | 4996 base::IntToString(params.transition)); |
| (...skipping 1846 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6843 // event target. Potentially a Pepper plugin will receive the event. | 6843 // event target. Potentially a Pepper plugin will receive the event. |
| 6844 // In order to tell whether a plugin gets the last mouse event and which it | 6844 // In order to tell whether a plugin gets the last mouse event and which it |
| 6845 // is, we set |pepper_last_mouse_event_target_| to null here. If a plugin gets | 6845 // is, we set |pepper_last_mouse_event_target_| to null here. If a plugin gets |
| 6846 // the event, it will notify us via DidReceiveMouseEvent() and set itself as | 6846 // the event, it will notify us via DidReceiveMouseEvent() and set itself as |
| 6847 // |pepper_last_mouse_event_target_|. | 6847 // |pepper_last_mouse_event_target_|. |
| 6848 pepper_last_mouse_event_target_ = nullptr; | 6848 pepper_last_mouse_event_target_ = nullptr; |
| 6849 #endif | 6849 #endif |
| 6850 } | 6850 } |
| 6851 | 6851 |
| 6852 } // namespace content | 6852 } // namespace content |
| OLD | NEW |