| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/extensions/activity_log/activity_log.h" | 5 #include "chrome/browser/extensions/activity_log/activity_log.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <set> | 8 #include <set> |
| 9 #include <utility> | 9 #include <utility> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 505 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 516 activity_monitor::Monitor current_function_monitor = | 516 activity_monitor::Monitor current_function_monitor = |
| 517 activity_monitor::GetApiFunctionMonitor(); | 517 activity_monitor::GetApiFunctionMonitor(); |
| 518 DCHECK(!current_function_monitor || | 518 DCHECK(!current_function_monitor || |
| 519 current_function_monitor == &LogApiFunction); | 519 current_function_monitor == &LogApiFunction); |
| 520 if (!current_function_monitor) | 520 if (!current_function_monitor) |
| 521 activity_monitor::SetApiFunctionMonitor(&LogApiFunction); | 521 activity_monitor::SetApiFunctionMonitor(&LogApiFunction); |
| 522 | 522 |
| 523 activity_monitor::Monitor current_event_monitor = | 523 activity_monitor::Monitor current_event_monitor = |
| 524 activity_monitor::GetApiEventMonitor(); | 524 activity_monitor::GetApiEventMonitor(); |
| 525 DCHECK(!current_event_monitor || current_event_monitor == &LogApiEvent); | 525 DCHECK(!current_event_monitor || current_event_monitor == &LogApiEvent); |
| 526 if (!current_function_monitor) | 526 if (!current_event_monitor) |
| 527 activity_monitor::SetApiEventMonitor(&LogApiEvent); | 527 activity_monitor::SetApiEventMonitor(&LogApiEvent); |
| 528 | 528 |
| 529 activity_monitor::WebRequestMonitor current_web_request_monitor = | 529 activity_monitor::WebRequestMonitor current_web_request_monitor = |
| 530 activity_monitor::GetWebRequestMonitor(); | 530 activity_monitor::GetWebRequestMonitor(); |
| 531 DCHECK(!current_web_request_monitor || | 531 DCHECK(!current_web_request_monitor || |
| 532 current_web_request_monitor == &LogWebRequestActivity); | 532 current_web_request_monitor == &LogWebRequestActivity); |
| 533 if (!current_web_request_monitor) | 533 if (!current_web_request_monitor) |
| 534 activity_monitor::SetWebRequestMonitor(&LogWebRequestActivity); | 534 activity_monitor::SetWebRequestMonitor(&LogWebRequestActivity); |
| 535 } | 535 } |
| 536 | 536 |
| (...skipping 402 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 939 } | 939 } |
| 940 } | 940 } |
| 941 | 941 |
| 942 template <> | 942 template <> |
| 943 void BrowserContextKeyedAPIFactory<ActivityLog>::DeclareFactoryDependencies() { | 943 void BrowserContextKeyedAPIFactory<ActivityLog>::DeclareFactoryDependencies() { |
| 944 DependsOn(ExtensionsBrowserClient::Get()->GetExtensionSystemFactory()); | 944 DependsOn(ExtensionsBrowserClient::Get()->GetExtensionSystemFactory()); |
| 945 DependsOn(ExtensionRegistryFactory::GetInstance()); | 945 DependsOn(ExtensionRegistryFactory::GetInstance()); |
| 946 } | 946 } |
| 947 | 947 |
| 948 } // namespace extensions | 948 } // namespace extensions |
| OLD | NEW |