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 <set> | 7 #include <set> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
(...skipping 527 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
538 dom_verb == DomActionType::METHOD) { | 538 dom_verb == DomActionType::METHOD) { |
539 other->SetInteger(constants::kActionDomVerb, DomActionType::XHR); | 539 other->SetInteger(constants::kActionDomVerb, DomActionType::XHR); |
540 } | 540 } |
541 } | 541 } |
542 | 542 |
543 if (uma_policy_) | 543 if (uma_policy_) |
544 uma_policy_->ProcessAction(action); | 544 uma_policy_->ProcessAction(action); |
545 if (IsDatabaseEnabled() && database_policy_) | 545 if (IsDatabaseEnabled() && database_policy_) |
546 database_policy_->ProcessAction(action); | 546 database_policy_->ProcessAction(action); |
547 if (IsWatchdogAppActive()) | 547 if (IsWatchdogAppActive()) |
548 observers_->Notify(&Observer::OnExtensionActivity, action); | 548 observers_->Notify(FROM_HERE, &Observer::OnExtensionActivity, action); |
549 if (testing_mode_) | 549 if (testing_mode_) |
550 VLOG(1) << action->PrintForDebug(); | 550 VLOG(1) << action->PrintForDebug(); |
551 } | 551 } |
552 | 552 |
553 void ActivityLog::OnScriptsExecuted( | 553 void ActivityLog::OnScriptsExecuted( |
554 const content::WebContents* web_contents, | 554 const content::WebContents* web_contents, |
555 const ExecutingScriptsMap& extension_ids, | 555 const ExecutingScriptsMap& extension_ids, |
556 const GURL& on_url) { | 556 const GURL& on_url) { |
557 Profile* profile = | 557 Profile* profile = |
558 Profile::FromBrowserContext(web_contents->GetBrowserContext()); | 558 Profile::FromBrowserContext(web_contents->GetBrowserContext()); |
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
674 database_policy_->DeleteDatabase(); | 674 database_policy_->DeleteDatabase(); |
675 } | 675 } |
676 | 676 |
677 template <> | 677 template <> |
678 void BrowserContextKeyedAPIFactory<ActivityLog>::DeclareFactoryDependencies() { | 678 void BrowserContextKeyedAPIFactory<ActivityLog>::DeclareFactoryDependencies() { |
679 DependsOn(ExtensionsBrowserClient::Get()->GetExtensionSystemFactory()); | 679 DependsOn(ExtensionsBrowserClient::Get()->GetExtensionSystemFactory()); |
680 DependsOn(ExtensionRegistryFactory::GetInstance()); | 680 DependsOn(ExtensionRegistryFactory::GetInstance()); |
681 } | 681 } |
682 | 682 |
683 } // namespace extensions | 683 } // namespace extensions |
OLD | NEW |