OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #include "chrome/browser/extensions/install_tracker.h" | |
6 | |
7 namespace extensions { | |
8 | |
9 InstallTracker::InstallTracker() { | |
10 } | |
11 | |
12 InstallTracker::~InstallTracker() { | |
13 } | |
14 | |
15 void InstallTracker::OnBeginExtensionInstall( | |
16 const std::string& extension_id, | |
17 const std::string& extension_name, | |
18 const gfx::ImageSkia& installing_icon, | |
19 bool is_app) { | |
20 FOR_EACH_OBSERVER(InstallObserver, observers_, | |
21 OnBeginExtensionInstall(extension_id, | |
tfarina
2013/02/25 23:43:02
If it fits I'd align with InstallObserver. Up to y
koz (OOO until 15th September)
2013/02/26 00:10:51
Done.
| |
22 extension_name, | |
23 installing_icon, | |
24 is_app)); | |
25 } | |
26 | |
27 void InstallTracker::OnDownloadProgress(const std::string& extension_id, | |
28 int percent_downloaded) { | |
29 FOR_EACH_OBSERVER(InstallObserver, observers_, | |
30 OnDownloadProgress(extension_id, percent_downloaded)); | |
31 } | |
32 | |
33 void InstallTracker::OnInstallFailure( | |
34 const std::string& extension_id) { | |
35 FOR_EACH_OBSERVER(InstallObserver, observers_, | |
36 OnInstallFailure(extension_id)); | |
tfarina
2013/02/25 23:43:02
If it fits I'd align with InstallObserver. Up to y
koz (OOO until 15th September)
2013/02/26 00:10:51
Done.
| |
37 } | |
38 | |
39 void InstallTracker::AddObserver(InstallObserver* observer) { | |
tfarina
2013/02/25 23:43:02
the order doesn't match with the order declared in
koz (OOO until 15th September)
2013/02/26 00:10:51
Done.
| |
40 observers_.AddObserver(observer); | |
41 } | |
42 | |
43 void InstallTracker::RemoveObserver(InstallObserver* observer) { | |
44 observers_.RemoveObserver(observer); | |
45 } | |
46 | |
47 } // namespace extensions | |
OLD | NEW |