| 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 3147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3158 double redirect_start = ConvertToBlinkTime( | 3158 double redirect_start = ConvertToBlinkTime( |
| 3159 navigation_state->request_params().navigation_timing.redirect_start); | 3159 navigation_state->request_params().navigation_timing.redirect_start); |
| 3160 double redirect_end = ConvertToBlinkTime( | 3160 double redirect_end = ConvertToBlinkTime( |
| 3161 navigation_state->request_params().navigation_timing.redirect_end); | 3161 navigation_state->request_params().navigation_timing.redirect_end); |
| 3162 double fetch_start = ConvertToBlinkTime( | 3162 double fetch_start = ConvertToBlinkTime( |
| 3163 navigation_state->request_params().navigation_timing.fetch_start); | 3163 navigation_state->request_params().navigation_timing.fetch_start); |
| 3164 std::vector<GURL> redirectChain = | 3164 std::vector<GURL> redirectChain = |
| 3165 navigation_state->request_params().redirects; | 3165 navigation_state->request_params().redirects; |
| 3166 redirectChain.push_back(navigation_state->common_params().url); | 3166 redirectChain.push_back(navigation_state->common_params().url); |
| 3167 | 3167 |
| 3168 datasource->updateNavigationTimings(redirect_start, redirect_end, | 3168 datasource->updateNavigation(redirect_start, redirect_end, fetch_start, |
| 3169 fetch_start, redirectChain); | 3169 redirectChain); |
| 3170 | |
| 3171 // TODO(clamy) We need to provide additional timing values for the | 3170 // TODO(clamy) We need to provide additional timing values for the |
| 3172 // Navigation Timing API to work with browser-side navigations. | 3171 // Navigation Timing API to work with browser-side navigations. |
| 3173 // UnloadEventStart and UnloadEventEnd are still missing. | 3172 // UnloadEventStart and UnloadEventEnd are still missing. |
| 3174 } | 3173 } |
| 3175 | 3174 |
| 3176 // Create the serviceworker's per-document network observing object if it | 3175 // Create the serviceworker's per-document network observing object if it |
| 3177 // does not exist (When navigation happens within a page, the provider already | 3176 // does not exist (When navigation happens within a page, the provider already |
| 3178 // exists). | 3177 // exists). |
| 3179 if (ServiceWorkerNetworkProvider::FromDocumentState( | 3178 if (ServiceWorkerNetworkProvider::FromDocumentState( |
| 3180 DocumentState::FromDataSource(datasource))) | 3179 DocumentState::FromDataSource(datasource))) |
| (...skipping 3162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6343 // event target. Potentially a Pepper plugin will receive the event. | 6342 // event target. Potentially a Pepper plugin will receive the event. |
| 6344 // In order to tell whether a plugin gets the last mouse event and which it | 6343 // In order to tell whether a plugin gets the last mouse event and which it |
| 6345 // is, we set |pepper_last_mouse_event_target_| to null here. If a plugin gets | 6344 // is, we set |pepper_last_mouse_event_target_| to null here. If a plugin gets |
| 6346 // the event, it will notify us via DidReceiveMouseEvent() and set itself as | 6345 // the event, it will notify us via DidReceiveMouseEvent() and set itself as |
| 6347 // |pepper_last_mouse_event_target_|. | 6346 // |pepper_last_mouse_event_target_|. |
| 6348 pepper_last_mouse_event_target_ = nullptr; | 6347 pepper_last_mouse_event_target_ = nullptr; |
| 6349 #endif | 6348 #endif |
| 6350 } | 6349 } |
| 6351 | 6350 |
| 6352 } // namespace content | 6351 } // namespace content |
| OLD | NEW |