Index: chrome/browser/apps/app_shim/app_shim_interactive_uitest_mac.mm |
diff --git a/chrome/browser/apps/app_shim/app_shim_interactive_uitest_mac.mm b/chrome/browser/apps/app_shim/app_shim_interactive_uitest_mac.mm |
index 6575b6d60aa3113fc2191a8556d02b0d627d7200..ea990bd9367ec7e31e32d3bde86d3b714c26a4fd 100644 |
--- a/chrome/browser/apps/app_shim/app_shim_interactive_uitest_mac.mm |
+++ b/chrome/browser/apps/app_shim/app_shim_interactive_uitest_mac.mm |
@@ -178,10 +178,11 @@ class AppLifetimeMonitorObserver : public apps::AppLifetimeMonitor::Observer { |
public: |
AppLifetimeMonitorObserver(Profile* profile) |
: profile_(profile), activated_count_(0), deactivated_count_(0) { |
- apps::AppLifetimeMonitorFactory::GetForProfile(profile_)->AddObserver(this); |
+ apps::AppLifetimeMonitorFactory::GetForBrowserContext(profile_) |
+ ->AddObserver(this); |
} |
~AppLifetimeMonitorObserver() override { |
- apps::AppLifetimeMonitorFactory::GetForProfile(profile_) |
+ apps::AppLifetimeMonitorFactory::GetForBrowserContext(profile_) |
->RemoveObserver(this); |
} |
@@ -190,10 +191,12 @@ class AppLifetimeMonitorObserver : public apps::AppLifetimeMonitor::Observer { |
protected: |
// AppLifetimeMonitor::Observer overrides: |
- void OnAppActivated(Profile* profile, const std::string& app_id) override { |
+ void OnAppActivated(content::BrowserContext* context, |
+ const std::string& app_id) override { |
++activated_count_; |
} |
- void OnAppDeactivated(Profile* profile, const std::string& app_id) override { |
+ void OnAppDeactivated(content::BrowserContext* context, |
+ const std::string& app_id) override { |
++deactivated_count_; |
} |