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

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

Issue 4687005: Track permissions granted to extensions in prefs (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix mac test failure Created 10 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) 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/extensions/crx_installer.h" 5 #include "chrome/browser/extensions/crx_installer.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #include "app/l10n_util.h" 9 #include "app/l10n_util.h"
10 #include "app/resource_bundle.h" 10 #include "app/resource_bundle.h"
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 } 76 }
77 return false; 77 return false;
78 } 78 }
79 79
80 CrxInstaller::CrxInstaller(ExtensionsService* frontend, 80 CrxInstaller::CrxInstaller(ExtensionsService* frontend,
81 ExtensionInstallUI* client) 81 ExtensionInstallUI* client)
82 : install_directory_(frontend->install_directory()), 82 : install_directory_(frontend->install_directory()),
83 install_source_(Extension::INTERNAL), 83 install_source_(Extension::INTERNAL),
84 extensions_enabled_(frontend->extensions_enabled()), 84 extensions_enabled_(frontend->extensions_enabled()),
85 delete_source_(false), 85 delete_source_(false),
86 allow_privilege_increase_(false),
87 is_gallery_install_(false), 86 is_gallery_install_(false),
88 create_app_shortcut_(false), 87 create_app_shortcut_(false),
89 frontend_(frontend), 88 frontend_(frontend),
90 client_(client), 89 client_(client),
91 apps_require_extension_mime_type_(false), 90 apps_require_extension_mime_type_(false),
92 allow_silent_install_(false) { 91 allow_silent_install_(false) {
93 } 92 }
94 93
95 CrxInstaller::~CrxInstaller() { 94 CrxInstaller::~CrxInstaller() {
96 // Delete the temp directory and crx file as necessary. Note that the 95 // Delete the temp directory and crx file as necessary. Note that the
(...skipping 329 matching lines...) Expand 10 before | Expand all | Expand 10 after
426 425
427 void CrxInstaller::ReportSuccessFromUIThread() { 426 void CrxInstaller::ReportSuccessFromUIThread() {
428 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 427 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
429 428
430 // If there is a client, tell the client about installation. 429 // If there is a client, tell the client about installation.
431 if (client_) 430 if (client_)
432 client_->OnInstallSuccess(extension_.get()); 431 client_->OnInstallSuccess(extension_.get());
433 432
434 // Tell the frontend about the installation and hand off ownership of 433 // Tell the frontend about the installation and hand off ownership of
435 // extension_ to it. 434 // extension_ to it.
436 frontend_->OnExtensionInstalled(extension_, allow_privilege_increase_); 435 frontend_->OnExtensionInstalled(extension_);
437 extension_ = NULL; 436 extension_ = NULL;
438 437
439 // We're done. We don't post any more tasks to ourselves so we are deleted 438 // We're done. We don't post any more tasks to ourselves so we are deleted
440 // soon. 439 // soon.
441 } 440 }
OLDNEW
« no previous file with comments | « chrome/browser/extensions/crx_installer.h ('k') | chrome/browser/extensions/extension_disabled_infobar_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698