Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(165)

Side by Side Diff: chrome/browser/extensions/crx_installer.cc

Issue 8919017: Split UserMetrics into API vs. implementation. Move API to content/public. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Version for commit (merged again). Created 9 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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/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 14 matching lines...) Expand all
25 #include "chrome/browser/extensions/convert_web_app.h" 25 #include "chrome/browser/extensions/convert_web_app.h"
26 #include "chrome/browser/extensions/default_apps_trial.h" 26 #include "chrome/browser/extensions/default_apps_trial.h"
27 #include "chrome/browser/extensions/extension_error_reporter.h" 27 #include "chrome/browser/extensions/extension_error_reporter.h"
28 #include "chrome/browser/extensions/extension_service.h" 28 #include "chrome/browser/extensions/extension_service.h"
29 #include "chrome/browser/shell_integration.h" 29 #include "chrome/browser/shell_integration.h"
30 #include "chrome/browser/web_applications/web_app.h" 30 #include "chrome/browser/web_applications/web_app.h"
31 #include "chrome/common/chrome_notification_types.h" 31 #include "chrome/common/chrome_notification_types.h"
32 #include "chrome/common/chrome_paths.h" 32 #include "chrome/common/chrome_paths.h"
33 #include "chrome/common/extensions/extension_constants.h" 33 #include "chrome/common/extensions/extension_constants.h"
34 #include "chrome/common/extensions/extension_file_util.h" 34 #include "chrome/common/extensions/extension_file_util.h"
35 #include "content/browser/user_metrics.h"
36 #include "content/public/browser/browser_thread.h" 35 #include "content/public/browser/browser_thread.h"
37 #include "content/public/browser/notification_service.h" 36 #include "content/public/browser/notification_service.h"
37 #include "content/public/browser/user_metrics.h"
38 #include "grit/chromium_strings.h" 38 #include "grit/chromium_strings.h"
39 #include "grit/generated_resources.h" 39 #include "grit/generated_resources.h"
40 #include "grit/theme_resources.h" 40 #include "grit/theme_resources.h"
41 #include "third_party/skia/include/core/SkBitmap.h" 41 #include "third_party/skia/include/core/SkBitmap.h"
42 #include "ui/base/l10n/l10n_util.h" 42 #include "ui/base/l10n/l10n_util.h"
43 #include "ui/base/resource/resource_bundle.h" 43 #include "ui/base/resource/resource_bundle.h"
44 44
45 using content::BrowserThread; 45 using content::BrowserThread;
46 using content::UserMetricsAction;
46 47
47 namespace { 48 namespace {
48 49
49 struct Whitelist { 50 struct Whitelist {
50 Whitelist() {} 51 Whitelist() {}
51 std::set<std::string> ids; 52 std::set<std::string> ids;
52 std::map<std::string, linked_ptr<CrxInstaller::WhitelistEntry> > entries; 53 std::map<std::string, linked_ptr<CrxInstaller::WhitelistEntry> > entries;
53 }; 54 };
54 55
55 static base::LazyInstance<Whitelist> 56 static base::LazyInstance<Whitelist>
(...skipping 545 matching lines...) Expand 10 before | Expand all | Expand 10 after
601 // Some users (such as the download shelf) need to know when a 602 // Some users (such as the download shelf) need to know when a
602 // CRXInstaller is done. Listening for the EXTENSION_* events 603 // CRXInstaller is done. Listening for the EXTENSION_* events
603 // is problematic because they don't know anything about the 604 // is problematic because they don't know anything about the
604 // extension before it is unpacked, so they cannot filter based 605 // extension before it is unpacked, so they cannot filter based
605 // on the extension. 606 // on the extension.
606 content::NotificationService::current()->Notify( 607 content::NotificationService::current()->Notify(
607 chrome::NOTIFICATION_CRX_INSTALLER_DONE, 608 chrome::NOTIFICATION_CRX_INSTALLER_DONE,
608 content::Source<CrxInstaller>(this), 609 content::Source<CrxInstaller>(this),
609 content::Details<const Extension>(extension)); 610 content::Details<const Extension>(extension));
610 } 611 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698