OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/chromeos/enterprise_extension_observer.h" | 5 #include "chrome/browser/chromeos/enterprise_extension_observer.h" |
6 | 6 |
7 #include "base/file_util.h" | 7 #include "base/file_util.h" |
8 #include "chrome/browser/browser_thread.h" | 8 #include "chrome/browser/browser_thread.h" |
9 #include "chrome/browser/chromeos/cros/cros_library.h" | 9 #include "chrome/browser/chromeos/cros/cros_library.h" |
10 #include "chrome/browser/chromeos/cros/login_library.h" | 10 #include "chrome/browser/chromeos/cros/login_library.h" |
11 #include "chrome/browser/profile.h" | 11 #include "chrome/browser/profiles/profile.h" |
12 | 12 |
13 namespace chromeos { | 13 namespace chromeos { |
14 | 14 |
15 EnterpriseExtensionObserver::EnterpriseExtensionObserver(Profile* profile) | 15 EnterpriseExtensionObserver::EnterpriseExtensionObserver(Profile* profile) |
16 : profile_(profile) { | 16 : profile_(profile) { |
17 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); | 17 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
18 registrar_.Add(this, | 18 registrar_.Add(this, |
19 NotificationType::EXTENSION_INSTALLED, | 19 NotificationType::EXTENSION_INSTALLED, |
20 Source<Profile>(profile_)); | 20 Source<Profile>(profile_)); |
21 } | 21 } |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
56 // static | 56 // static |
57 void EnterpriseExtensionObserver::NotifyEntd() { | 57 void EnterpriseExtensionObserver::NotifyEntd() { |
58 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); | 58 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
59 if (CrosLibrary::Get()->EnsureLoaded()) { | 59 if (CrosLibrary::Get()->EnsureLoaded()) { |
60 CrosLibrary::Get()->GetLoginLibrary()->RestartEntd(); | 60 CrosLibrary::Get()->GetLoginLibrary()->RestartEntd(); |
61 return; | 61 return; |
62 } | 62 } |
63 } | 63 } |
64 | 64 |
65 } // namespace chromeos | 65 } // namespace chromeos |
OLD | NEW |