| 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_API_DOWNLOADS_DOWNLOADS_API_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_API_DOWNLOADS_DOWNLOADS_API_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_API_DOWNLOADS_DOWNLOADS_API_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_API_DOWNLOADS_DOWNLOADS_API_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 88 class DownloadsDownloadFunction : public ChromeAsyncExtensionFunction { | 88 class DownloadsDownloadFunction : public ChromeAsyncExtensionFunction { |
| 89 public: | 89 public: |
| 90 DECLARE_EXTENSION_FUNCTION("downloads.download", DOWNLOADS_DOWNLOAD) | 90 DECLARE_EXTENSION_FUNCTION("downloads.download", DOWNLOADS_DOWNLOAD) |
| 91 DownloadsDownloadFunction(); | 91 DownloadsDownloadFunction(); |
| 92 virtual bool RunImpl() OVERRIDE; | 92 virtual bool RunImpl() OVERRIDE; |
| 93 | 93 |
| 94 protected: | 94 protected: |
| 95 virtual ~DownloadsDownloadFunction(); | 95 virtual ~DownloadsDownloadFunction(); |
| 96 | 96 |
| 97 private: | 97 private: |
| 98 void OnStarted( | 98 void OnStarted(const base::FilePath& creator_suggested_filename, |
| 99 const base::FilePath& creator_suggested_filename, | 99 extensions::api::downloads::FilenameConflictAction |
| 100 extensions::api::downloads::FilenameConflictAction | 100 creator_conflict_action, |
| 101 creator_conflict_action, | 101 content::DownloadItem* item, |
| 102 content::DownloadItem* item, | 102 content::DownloadInterruptReason interrupt_reason); |
| 103 net::Error error); | |
| 104 | 103 |
| 105 DISALLOW_COPY_AND_ASSIGN(DownloadsDownloadFunction); | 104 DISALLOW_COPY_AND_ASSIGN(DownloadsDownloadFunction); |
| 106 }; | 105 }; |
| 107 | 106 |
| 108 class DownloadsSearchFunction : public ChromeSyncExtensionFunction { | 107 class DownloadsSearchFunction : public ChromeSyncExtensionFunction { |
| 109 public: | 108 public: |
| 110 DECLARE_EXTENSION_FUNCTION("downloads.search", DOWNLOADS_SEARCH) | 109 DECLARE_EXTENSION_FUNCTION("downloads.search", DOWNLOADS_SEARCH) |
| 111 DownloadsSearchFunction(); | 110 DownloadsSearchFunction(); |
| 112 virtual bool RunImpl() OVERRIDE; | 111 virtual bool RunImpl() OVERRIDE; |
| 113 | 112 |
| (...skipping 279 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 393 | 392 |
| 394 Profile* profile_; | 393 Profile* profile_; |
| 395 AllDownloadItemNotifier notifier_; | 394 AllDownloadItemNotifier notifier_; |
| 396 std::set<const extensions::Extension*> shelf_disabling_extensions_; | 395 std::set<const extensions::Extension*> shelf_disabling_extensions_; |
| 397 content::NotificationRegistrar registrar_; | 396 content::NotificationRegistrar registrar_; |
| 398 | 397 |
| 399 DISALLOW_COPY_AND_ASSIGN(ExtensionDownloadsEventRouter); | 398 DISALLOW_COPY_AND_ASSIGN(ExtensionDownloadsEventRouter); |
| 400 }; | 399 }; |
| 401 | 400 |
| 402 #endif // CHROME_BROWSER_EXTENSIONS_API_DOWNLOADS_DOWNLOADS_API_H_ | 401 #endif // CHROME_BROWSER_EXTENSIONS_API_DOWNLOADS_DOWNLOADS_API_H_ |
| OLD | NEW |