| 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 | 5 |
| 6 #ifndef CHROME_BROWSER_UI_WEBUI_CHROMEOS_IMAGEBURNER_IMAGEBURNER_UTILS_H_ | 6 #ifndef CHROME_BROWSER_UI_WEBUI_CHROMEOS_IMAGEBURNER_IMAGEBURNER_UTILS_H_ |
| 7 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_IMAGEBURNER_IMAGEBURNER_UTILS_H_ | 7 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_IMAGEBURNER_IMAGEBURNER_UTILS_H_ |
| 8 | 8 |
| 9 #include <map> | 9 #include <map> |
| 10 #include <set> | 10 #include <set> |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 #include "content/browser/download/download_manager.h" | 21 #include "content/browser/download/download_manager.h" |
| 22 #include "content/browser/tab_contents/tab_contents.h" | 22 #include "content/browser/tab_contents/tab_contents.h" |
| 23 #include "googleurl/src/gurl.h" | 23 #include "googleurl/src/gurl.h" |
| 24 #include "net/base/file_stream.h" | 24 #include "net/base/file_stream.h" |
| 25 #include "ui/base/dragdrop/download_file_interface.h" | 25 #include "ui/base/dragdrop/download_file_interface.h" |
| 26 | 26 |
| 27 | 27 |
| 28 namespace imageburner { | 28 namespace imageburner { |
| 29 | 29 |
| 30 // Config file properties. | 30 // Config file properties. |
| 31 static const std::string kRecoveryToolVersion = "recovery_tool_version"; | 31 extern const char kName[]; |
| 32 static const std::string kRecoveryToolLinuxVersion = | 32 extern const char kHwid[]; |
| 33 "recovery_tool_linux_version"; | 33 extern const char kFileName[]; |
| 34 static const std::string kName = "name"; | 34 extern const char kUrl[]; |
| 35 static const std::string kVersion = "version"; | |
| 36 static const std::string kDescription = "desc"; | |
| 37 static const std::string kChannel = "channel"; | |
| 38 static const std::string kHwid = "hwid"; | |
| 39 static const std::string kSha1 = "sha1"; | |
| 40 static const std::string kZipFileSize = "zipfilesize"; | |
| 41 static const std::string kFileSize = "filesize"; | |
| 42 static const std::string kFileName = "file"; | |
| 43 static const std::string kUrl = "url"; | |
| 44 | 35 |
| 45 class Downloader { | 36 class Downloader { |
| 46 public: | 37 public: |
| 47 class Listener : public base::SupportsWeakPtr<Listener> { | 38 class Listener : public base::SupportsWeakPtr<Listener> { |
| 48 public: | 39 public: |
| 49 // After download starts download status updates can be followed through | 40 // After download starts download status updates can be followed through |
| 50 // DownloadItem::Observer interface. | 41 // DownloadItem::Observer interface. |
| 51 virtual void OnBurnDownloadStarted(bool success) = 0; | 42 virtual void OnBurnDownloadStarted(bool success) = 0; |
| 52 }; | 43 }; |
| 53 | 44 |
| (...skipping 259 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 313 scoped_ptr<StateMachine> state_machine_; | 304 scoped_ptr<StateMachine> state_machine_; |
| 314 | 305 |
| 315 scoped_ptr<Downloader> downloader_; | 306 scoped_ptr<Downloader> downloader_; |
| 316 | 307 |
| 317 DISALLOW_COPY_AND_ASSIGN(BurnManager); | 308 DISALLOW_COPY_AND_ASSIGN(BurnManager); |
| 318 }; | 309 }; |
| 319 | 310 |
| 320 } // namespace imageburner. | 311 } // namespace imageburner. |
| 321 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_IMAGEBURNER_IMAGEBURNER_UTILS_H_ | 312 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_IMAGEBURNER_IMAGEBURNER_UTILS_H_ |
| 322 | 313 |
| OLD | NEW |