OLD | NEW |
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 #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 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
136 | 136 |
137 extension_misc::CrxInstallCause install_cause() const { | 137 extension_misc::CrxInstallCause install_cause() const { |
138 return install_cause_; | 138 return install_cause_; |
139 } | 139 } |
140 | 140 |
141 void set_install_cause(extension_misc::CrxInstallCause install_cause) { | 141 void set_install_cause(extension_misc::CrxInstallCause install_cause) { |
142 install_cause_ = install_cause; | 142 install_cause_ = install_cause; |
143 } | 143 } |
144 | 144 |
145 private: | 145 private: |
146 ~CrxInstaller(); | 146 virtual ~CrxInstaller(); |
147 | 147 |
148 // Converts the source user script to an extension. | 148 // Converts the source user script to an extension. |
149 void ConvertUserScriptOnFileThread(); | 149 void ConvertUserScriptOnFileThread(); |
150 | 150 |
151 // Converts the source web app to an extension. | 151 // Converts the source web app to an extension. |
152 void ConvertWebAppOnFileThread(const WebApplicationInfo& web_app); | 152 void ConvertWebAppOnFileThread(const WebApplicationInfo& web_app); |
153 | 153 |
154 // Called after OnUnpackSuccess as a last check to see whether the install | 154 // Called after OnUnpackSuccess as a last check to see whether the install |
155 // should complete. | 155 // should complete. |
156 bool AllowInstall(const Extension* extension, std::string* error); | 156 bool AllowInstall(const Extension* extension, std::string* error); |
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
264 std::string original_mime_type_; | 264 std::string original_mime_type_; |
265 | 265 |
266 // What caused this install? Used only for histograms that report | 266 // What caused this install? Used only for histograms that report |
267 // on failure rates, broken down by the cause of the install. | 267 // on failure rates, broken down by the cause of the install. |
268 extension_misc::CrxInstallCause install_cause_; | 268 extension_misc::CrxInstallCause install_cause_; |
269 | 269 |
270 DISALLOW_COPY_AND_ASSIGN(CrxInstaller); | 270 DISALLOW_COPY_AND_ASSIGN(CrxInstaller); |
271 }; | 271 }; |
272 | 272 |
273 #endif // CHROME_BROWSER_EXTENSIONS_CRX_INSTALLER_H_ | 273 #endif // CHROME_BROWSER_EXTENSIONS_CRX_INSTALLER_H_ |
OLD | NEW |