OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/crx_installer.h" | 5 #include "chrome/browser/extensions/crx_installer.h" |
6 | 6 |
7 #include <map> | 7 #include <map> |
8 #include <set> | 8 #include <set> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
42 #include "content/public/browser/user_metrics.h" | 42 #include "content/public/browser/user_metrics.h" |
43 #include "grit/chromium_strings.h" | 43 #include "grit/chromium_strings.h" |
44 #include "grit/generated_resources.h" | 44 #include "grit/generated_resources.h" |
45 #include "grit/theme_resources.h" | 45 #include "grit/theme_resources.h" |
46 #include "third_party/skia/include/core/SkBitmap.h" | 46 #include "third_party/skia/include/core/SkBitmap.h" |
47 #include "ui/base/l10n/l10n_util.h" | 47 #include "ui/base/l10n/l10n_util.h" |
48 #include "ui/base/resource/resource_bundle.h" | 48 #include "ui/base/resource/resource_bundle.h" |
49 | 49 |
50 using content::BrowserThread; | 50 using content::BrowserThread; |
51 using content::UserMetricsAction; | 51 using content::UserMetricsAction; |
| 52 using extensions::Extension; |
52 using extensions::PermissionsUpdater; | 53 using extensions::PermissionsUpdater; |
53 | 54 |
54 // static | 55 // static |
55 scoped_refptr<CrxInstaller> CrxInstaller::Create( | 56 scoped_refptr<CrxInstaller> CrxInstaller::Create( |
56 ExtensionService* frontend, | 57 ExtensionService* frontend, |
57 ExtensionInstallUI* client) { | 58 ExtensionInstallUI* client) { |
58 return new CrxInstaller(frontend->AsWeakPtr(), client, NULL); | 59 return new CrxInstaller(frontend->AsWeakPtr(), client, NULL); |
59 } | 60 } |
60 | 61 |
61 // static | 62 // static |
(...skipping 488 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
550 // Some users (such as the download shelf) need to know when a | 551 // Some users (such as the download shelf) need to know when a |
551 // CRXInstaller is done. Listening for the EXTENSION_* events | 552 // CRXInstaller is done. Listening for the EXTENSION_* events |
552 // is problematic because they don't know anything about the | 553 // is problematic because they don't know anything about the |
553 // extension before it is unpacked, so they cannot filter based | 554 // extension before it is unpacked, so they cannot filter based |
554 // on the extension. | 555 // on the extension. |
555 content::NotificationService::current()->Notify( | 556 content::NotificationService::current()->Notify( |
556 chrome::NOTIFICATION_CRX_INSTALLER_DONE, | 557 chrome::NOTIFICATION_CRX_INSTALLER_DONE, |
557 content::Source<CrxInstaller>(this), | 558 content::Source<CrxInstaller>(this), |
558 content::Details<const Extension>(extension)); | 559 content::Details<const Extension>(extension)); |
559 } | 560 } |
OLD | NEW |