| 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 #ifndef CHROME_BROWSER_EXTENSIONS_CRX_INSTALLER_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_CRX_INSTALLER_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_CRX_INSTALLER_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_CRX_INSTALLER_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 135 apps_require_extension_mime_type_ = apps_require_extension_mime_type; | 135 apps_require_extension_mime_type_ = apps_require_extension_mime_type; |
| 136 } | 136 } |
| 137 | 137 |
| 138 void set_original_mime_type(const std::string& original_mime_type) { | 138 void set_original_mime_type(const std::string& original_mime_type) { |
| 139 original_mime_type_ = original_mime_type; | 139 original_mime_type_ = original_mime_type; |
| 140 } | 140 } |
| 141 | 141 |
| 142 extension_misc::CrxInstallCause install_cause() const { | 142 extension_misc::CrxInstallCause install_cause() const { |
| 143 return install_cause_; | 143 return install_cause_; |
| 144 } | 144 } |
| 145 | |
| 146 void set_install_cause(extension_misc::CrxInstallCause install_cause) { | 145 void set_install_cause(extension_misc::CrxInstallCause install_cause) { |
| 147 install_cause_ = install_cause; | 146 install_cause_ = install_cause; |
| 148 } | 147 } |
| 149 | 148 |
| 149 bool allow_off_store_install() const { return allow_off_store_install_; } |
| 150 void set_allow_off_store_install(bool val) { allow_off_store_install_ = val; } |
| 151 |
| 150 void set_page_ordinal(const StringOrdinal& page_ordinal) { | 152 void set_page_ordinal(const StringOrdinal& page_ordinal) { |
| 151 page_ordinal_ = page_ordinal; | 153 page_ordinal_ = page_ordinal; |
| 152 } | 154 } |
| 153 | 155 |
| 154 Profile* profile() { return profile_; } | 156 Profile* profile() { return profile_; } |
| 155 | 157 |
| 156 private: | 158 private: |
| 157 friend class extensions::ExtensionUpdaterTest; | 159 friend class extensions::ExtensionUpdaterTest; |
| 158 | 160 |
| 159 CrxInstaller(base::WeakPtr<ExtensionService> frontend_weak, | 161 CrxInstaller(base::WeakPtr<ExtensionService> frontend_weak, |
| (...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 302 std::string original_mime_type_; | 304 std::string original_mime_type_; |
| 303 | 305 |
| 304 // What caused this install? Used only for histograms that report | 306 // What caused this install? Used only for histograms that report |
| 305 // on failure rates, broken down by the cause of the install. | 307 // on failure rates, broken down by the cause of the install. |
| 306 extension_misc::CrxInstallCause install_cause_; | 308 extension_misc::CrxInstallCause install_cause_; |
| 307 | 309 |
| 308 // Creation flags to use for the extension. These flags will be used | 310 // Creation flags to use for the extension. These flags will be used |
| 309 // when calling Extenion::Create() by the crx installer. | 311 // when calling Extenion::Create() by the crx installer. |
| 310 int creation_flags_; | 312 int creation_flags_; |
| 311 | 313 |
| 314 // Whether to allow off store installation. |
| 315 bool allow_off_store_install_; |
| 316 |
| 312 DISALLOW_COPY_AND_ASSIGN(CrxInstaller); | 317 DISALLOW_COPY_AND_ASSIGN(CrxInstaller); |
| 313 }; | 318 }; |
| 314 | 319 |
| 315 #endif // CHROME_BROWSER_EXTENSIONS_CRX_INSTALLER_H_ | 320 #endif // CHROME_BROWSER_EXTENSIONS_CRX_INSTALLER_H_ |
| OLD | NEW |