OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/ui/webui/performance_monitor/web_ui_handler.h" | 5 #include "chrome/browser/ui/webui/performance_monitor/web_ui_handler.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/bind_helpers.h" | 8 #include "base/bind_helpers.h" |
9 #include "base/time.h" | 9 #include "base/time.h" |
10 #include "base/values.h" | 10 #include "base/values.h" |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
57 event_set.insert(EVENT_EXTENSION_INSTALL); | 57 event_set.insert(EVENT_EXTENSION_INSTALL); |
58 event_set.insert(EVENT_EXTENSION_UNINSTALL); | 58 event_set.insert(EVENT_EXTENSION_UNINSTALL); |
59 event_set.insert(EVENT_EXTENSION_UPDATE); | 59 event_set.insert(EVENT_EXTENSION_UPDATE); |
60 event_set.insert(EVENT_EXTENSION_ENABLE); | 60 event_set.insert(EVENT_EXTENSION_ENABLE); |
61 event_set.insert(EVENT_EXTENSION_DISABLE); | 61 event_set.insert(EVENT_EXTENSION_DISABLE); |
62 break; | 62 break; |
63 case EVENT_CATEGORY_CHROME: | 63 case EVENT_CATEGORY_CHROME: |
64 event_set.insert(EVENT_CHROME_UPDATE); | 64 event_set.insert(EVENT_CHROME_UPDATE); |
65 break; | 65 break; |
66 case EVENT_CATEGORY_EXCEPTIONS: | 66 case EVENT_CATEGORY_EXCEPTIONS: |
67 event_set.insert(EVENT_RENDERER_FREEZE); | 67 event_set.insert(EVENT_RENDERER_HANG); |
68 event_set.insert(EVENT_RENDERER_CRASH); | 68 event_set.insert(EVENT_RENDERER_CRASH); |
69 event_set.insert(EVENT_KILLED_BY_OS_CRASH); | 69 event_set.insert(EVENT_RENDERER_KILLED); |
70 event_set.insert(EVENT_UNCLEAN_EXIT); | 70 event_set.insert(EVENT_UNCLEAN_EXIT); |
71 break; | 71 break; |
72 default: | 72 default: |
73 NOTREACHED(); | 73 NOTREACHED(); |
74 } | 74 } |
75 return event_set; | 75 return event_set; |
76 } | 76 } |
77 | 77 |
78 Unit GetUnitForMetricCategory(MetricCategory category) { | 78 Unit GetUnitForMetricCategory(MetricCategory category) { |
79 switch (category) { | 79 switch (category) { |
(...skipping 376 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
456 util::PostTaskToDatabaseThreadAndReply( | 456 util::PostTaskToDatabaseThreadAndReply( |
457 FROM_HERE, | 457 FROM_HERE, |
458 base::Bind(&DoGetMetric, results, metric_type, | 458 base::Bind(&DoGetMetric, results, metric_type, |
459 start, end, resolution), | 459 start, end, resolution), |
460 base::Bind(&WebUIHandler::ReturnResults, AsWeakPtr(), | 460 base::Bind(&WebUIHandler::ReturnResults, AsWeakPtr(), |
461 "PerformanceMonitor.getMetricCallback", | 461 "PerformanceMonitor.getMetricCallback", |
462 base::Owned(results))); | 462 base::Owned(results))); |
463 } | 463 } |
464 | 464 |
465 } // namespace performance_monitor | 465 } // namespace performance_monitor |
OLD | NEW |