OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "components/page_load_metrics/browser/metrics_web_contents_observer.h" | 5 #include "chrome/browser/page_load_metrics/metrics_web_contents_observer.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <ostream> | 8 #include <ostream> |
9 #include <string> | 9 #include <string> |
10 #include <utility> | 10 #include <utility> |
11 | 11 |
12 #include "base/location.h" | 12 #include "base/location.h" |
13 #include "base/logging.h" | 13 #include "base/logging.h" |
14 #include "base/memory/ptr_util.h" | 14 #include "base/memory/ptr_util.h" |
15 #include "base/metrics/histogram.h" | 15 #include "base/metrics/histogram.h" |
16 #include "base/metrics/user_metrics.h" | 16 #include "base/metrics/user_metrics.h" |
17 #include "components/page_load_metrics/browser/page_load_metrics_util.h" | 17 #include "chrome/browser/page_load_metrics/page_load_metrics_util.h" |
18 #include "components/page_load_metrics/common/page_load_metrics_messages.h" | 18 #include "chrome/common/page_load_metrics/page_load_metrics_messages.h" |
19 #include "components/page_load_metrics/common/page_load_timing.h" | 19 #include "chrome/common/page_load_metrics/page_load_timing.h" |
20 #include "content/public/browser/browser_thread.h" | 20 #include "content/public/browser/browser_thread.h" |
21 #include "content/public/browser/navigation_details.h" | 21 #include "content/public/browser/navigation_details.h" |
22 #include "content/public/browser/navigation_handle.h" | 22 #include "content/public/browser/navigation_handle.h" |
23 #include "content/public/browser/render_frame_host.h" | 23 #include "content/public/browser/render_frame_host.h" |
24 #include "content/public/browser/render_view_host.h" | 24 #include "content/public/browser/render_view_host.h" |
25 #include "content/public/browser/web_contents.h" | 25 #include "content/public/browser/web_contents.h" |
26 #include "content/public/browser/web_contents_observer.h" | 26 #include "content/public/browser/web_contents_observer.h" |
27 #include "content/public/browser/web_contents_user_data.h" | 27 #include "content/public/browser/web_contents_user_data.h" |
28 #include "ipc/ipc_message.h" | 28 #include "ipc/ipc_message.h" |
29 #include "ipc/ipc_message_macros.h" | 29 #include "ipc/ipc_message_macros.h" |
(...skipping 921 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
951 if (navigation_handle->IsSamePage() || navigation_handle->IsErrorPage()) | 951 if (navigation_handle->IsSamePage() || navigation_handle->IsErrorPage()) |
952 return false; | 952 return false; |
953 const std::string& mime_type = web_contents()->GetContentsMimeType(); | 953 const std::string& mime_type = web_contents()->GetContentsMimeType(); |
954 if (mime_type != "text/html" && mime_type != "application/xhtml+xml") | 954 if (mime_type != "text/html" && mime_type != "application/xhtml+xml") |
955 return false; | 955 return false; |
956 } | 956 } |
957 return true; | 957 return true; |
958 } | 958 } |
959 | 959 |
960 } // namespace page_load_metrics | 960 } // namespace page_load_metrics |
OLD | NEW |