| 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 139 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 150 expected_manifest_check_level_ = approval->manifest_check_level; | 150 expected_manifest_check_level_ = approval->manifest_check_level; |
| 151 if (expected_manifest_check_level_ != | 151 if (expected_manifest_check_level_ != |
| 152 WebstoreInstaller::MANIFEST_CHECK_LEVEL_NONE) | 152 WebstoreInstaller::MANIFEST_CHECK_LEVEL_NONE) |
| 153 expected_manifest_.reset(approval->manifest->DeepCopy()); | 153 expected_manifest_.reset(approval->manifest->DeepCopy()); |
| 154 expected_id_ = approval->extension_id; | 154 expected_id_ = approval->extension_id; |
| 155 } | 155 } |
| 156 if (approval->minimum_version.get()) | 156 if (approval->minimum_version.get()) |
| 157 minimum_version_ = base::Version(*approval->minimum_version); | 157 minimum_version_ = base::Version(*approval->minimum_version); |
| 158 | 158 |
| 159 show_dialog_callback_ = approval->show_dialog_callback; | 159 show_dialog_callback_ = approval->show_dialog_callback; |
| 160 set_is_ephemeral(approval->is_ephemeral); | |
| 161 } | 160 } |
| 162 | 161 |
| 163 CrxInstaller::~CrxInstaller() { | 162 CrxInstaller::~CrxInstaller() { |
| 164 DCHECK_CURRENTLY_ON(BrowserThread::UI); | 163 DCHECK_CURRENTLY_ON(BrowserThread::UI); |
| 165 // Ensure |client_| and |install_checker_| data members are destroyed on the | 164 // Ensure |client_| and |install_checker_| data members are destroyed on the |
| 166 // UI thread. The |client_| dialog has a weak reference as |this| is its | 165 // UI thread. The |client_| dialog has a weak reference as |this| is its |
| 167 // delegate, and |install_checker_| owns WeakPtrs, so must be destroyed on the | 166 // delegate, and |install_checker_| owns WeakPtrs, so must be destroyed on the |
| 168 // same thread that created it. | 167 // same thread that created it. |
| 169 } | 168 } |
| 170 | 169 |
| (...skipping 730 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 901 if (!prefs->DidExtensionEscalatePermissions(extension()->id())) | 900 if (!prefs->DidExtensionEscalatePermissions(extension()->id())) |
| 902 return; | 901 return; |
| 903 | 902 |
| 904 if (client_) { | 903 if (client_) { |
| 905 AddRef(); // Balanced in InstallUIProceed() and InstallUIAbort(). | 904 AddRef(); // Balanced in InstallUIProceed() and InstallUIAbort(). |
| 906 client_->ConfirmReEnable(this, extension()); | 905 client_->ConfirmReEnable(this, extension()); |
| 907 } | 906 } |
| 908 } | 907 } |
| 909 | 908 |
| 910 } // namespace extensions | 909 } // namespace extensions |
| OLD | NEW |