OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef CHROME_BROWSER_METRICS_CHROME_STABILITY_METRICS_PROVIDER_H_ | 5 #ifndef CHROME_BROWSER_METRICS_CHROME_STABILITY_METRICS_PROVIDER_H_ |
6 #define CHROME_BROWSER_METRICS_CHROME_STABILITY_METRICS_PROVIDER_H_ | 6 #define CHROME_BROWSER_METRICS_CHROME_STABILITY_METRICS_PROVIDER_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/metrics/user_metrics.h" | 9 #include "base/metrics/user_metrics.h" |
10 #include "base/process/kill.h" | 10 #include "base/process/kill.h" |
(...skipping 30 matching lines...) Expand all Loading... |
41 static void RegisterPrefs(PrefRegistrySimple* registry); | 41 static void RegisterPrefs(PrefRegistrySimple* registry); |
42 | 42 |
43 private: | 43 private: |
44 // content::NotificationObserver: | 44 // content::NotificationObserver: |
45 void Observe(int type, | 45 void Observe(int type, |
46 const content::NotificationSource& source, | 46 const content::NotificationSource& source, |
47 const content::NotificationDetails& details) override; | 47 const content::NotificationDetails& details) override; |
48 | 48 |
49 // content::BrowserChildProcessObserver: | 49 // content::BrowserChildProcessObserver: |
50 void BrowserChildProcessCrashed( | 50 void BrowserChildProcessCrashed( |
51 const content::ChildProcessData& data) override; | 51 const content::ChildProcessData& data, |
| 52 int exit_code) override; |
52 | 53 |
53 // Logs the initiation of a page load and uses |web_contents| to do | 54 // Logs the initiation of a page load and uses |web_contents| to do |
54 // additional logging of the type of page loaded. | 55 // additional logging of the type of page loaded. |
55 void LogLoadStarted(content::WebContents* web_contents); | 56 void LogLoadStarted(content::WebContents* web_contents); |
56 | 57 |
57 // Records a renderer process crash. | 58 // Records a renderer process crash. |
58 void LogRendererCrash(content::RenderProcessHost* host, | 59 void LogRendererCrash(content::RenderProcessHost* host, |
59 base::TerminationStatus status, | 60 base::TerminationStatus status, |
60 int exit_code); | 61 int exit_code); |
61 | 62 |
62 // Records a renderer process hang. | 63 // Records a renderer process hang. |
63 void LogRendererHang(); | 64 void LogRendererHang(); |
64 | 65 |
65 // Registrar for receiving stability-related notifications. | 66 // Registrar for receiving stability-related notifications. |
66 content::NotificationRegistrar registrar_; | 67 content::NotificationRegistrar registrar_; |
67 | 68 |
68 DISALLOW_COPY_AND_ASSIGN(ChromeStabilityMetricsProvider); | 69 DISALLOW_COPY_AND_ASSIGN(ChromeStabilityMetricsProvider); |
69 }; | 70 }; |
70 | 71 |
71 #endif // CHROME_BROWSER_METRICS_CHROME_STABILITY_METRICS_PROVIDER_H_ | 72 #endif // CHROME_BROWSER_METRICS_CHROME_STABILITY_METRICS_PROVIDER_H_ |
OLD | NEW |