Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1270)

Side by Side Diff: chrome/browser/metrics/chrome_stability_metrics_provider.cc

Issue 2730283002: Cleanups in the wake of various metrics refactorings. (Closed)
Patch Set: Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | chrome/chrome_watcher/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include "chrome/browser/metrics/chrome_stability_metrics_provider.h" 5 #include "chrome/browser/metrics/chrome_stability_metrics_provider.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/metrics/histogram_macros.h" 10 #include "base/metrics/histogram_macros.h"
11 #include "base/metrics/sparse_histogram.h" 11 #include "base/metrics/sparse_histogram.h"
12 #include "build/build_config.h" 12 #include "build/build_config.h"
13 #include "chrome/browser/chrome_notification_types.h" 13 #include "chrome/browser/chrome_notification_types.h"
14 #include "content/public/browser/child_process_data.h" 14 #include "content/public/browser/child_process_data.h"
15 #include "content/public/browser/notification_service.h" 15 #include "content/public/browser/notification_service.h"
16 #include "content/public/browser/render_process_host.h" 16 #include "content/public/browser/render_process_host.h"
17 #include "extensions/features/features.h" 17 #include "extensions/features/features.h"
18 #include "ppapi/features/features.h" 18 #include "ppapi/features/features.h"
19 19
20 #if BUILDFLAG(ENABLE_EXTENSIONS) 20 #if BUILDFLAG(ENABLE_EXTENSIONS)
21 #include "extensions/browser/process_map.h" 21 #include "extensions/browser/process_map.h"
22 #endif 22 #endif
23 23
24 #if BUILDFLAG(ENABLE_PLUGINS) 24 #if BUILDFLAG(ENABLE_PLUGINS)
25 #include "chrome/browser/metrics/plugin_metrics_provider.h" 25 #include "chrome/browser/metrics/plugin_metrics_provider.h"
26 #endif 26 #endif
27 27
28 #if defined(OS_WIN)
29 #include <windows.h> // Needed for STATUS_* codes
30 #include "chrome/common/metrics_constants_util_win.h"
31 #endif
32
33 ChromeStabilityMetricsProvider::ChromeStabilityMetricsProvider( 28 ChromeStabilityMetricsProvider::ChromeStabilityMetricsProvider(
34 PrefService* local_state) 29 PrefService* local_state)
35 : helper_(local_state) { 30 : helper_(local_state) {
36 BrowserChildProcessObserver::Add(this); 31 BrowserChildProcessObserver::Add(this);
37 } 32 }
38 33
39 ChromeStabilityMetricsProvider::~ChromeStabilityMetricsProvider() { 34 ChromeStabilityMetricsProvider::~ChromeStabilityMetricsProvider() {
40 BrowserChildProcessObserver::Remove(this); 35 BrowserChildProcessObserver::Remove(this);
41 } 36 }
42 37
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 int exit_code) { 120 int exit_code) {
126 #if BUILDFLAG(ENABLE_PLUGINS) 121 #if BUILDFLAG(ENABLE_PLUGINS)
127 // Exclude plugin crashes from the count below because we report them via 122 // Exclude plugin crashes from the count below because we report them via
128 // a separate UMA metric. 123 // a separate UMA metric.
129 if (PluginMetricsProvider::IsPluginProcess(data.process_type)) 124 if (PluginMetricsProvider::IsPluginProcess(data.process_type))
130 return; 125 return;
131 #endif 126 #endif
132 127
133 helper_.BrowserChildProcessCrashed(); 128 helper_.BrowserChildProcessCrashed();
134 } 129 }
OLDNEW
« no previous file with comments | « no previous file | chrome/chrome_watcher/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698