| 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_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_H_ | 6 #define CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <map> | 9 #include <map> |
| 10 #include <string> | 10 #include <string> |
| (...skipping 818 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 829 GDataErrorCode status, | 829 GDataErrorCode status, |
| 830 scoped_ptr<base::Value> created_entry); | 830 scoped_ptr<base::Value> created_entry); |
| 831 | 831 |
| 832 // Callback for handling file downloading requests. | 832 // Callback for handling file downloading requests. |
| 833 void OnFileDownloaded( | 833 void OnFileDownloaded( |
| 834 const GetFileFromCacheParams& params, | 834 const GetFileFromCacheParams& params, |
| 835 GDataErrorCode status, | 835 GDataErrorCode status, |
| 836 const GURL& content_url, | 836 const GURL& content_url, |
| 837 const FilePath& downloaded_file_path); | 837 const FilePath& downloaded_file_path); |
| 838 | 838 |
| 839 // Unpins file if cache entry is pinned. |
| 840 void UnpinIfPinned(const FilePath& file_path, |
| 841 GDataCache::CacheEntry* cache_entry, |
| 842 bool* cache_entry_is_valid); |
| 843 |
| 839 // Similar to OnFileDownloaded() but takes |has_enough_space| so we report | 844 // Similar to OnFileDownloaded() but takes |has_enough_space| so we report |
| 840 // an error in case we don't have enough disk space. | 845 // an error in case we don't have enough disk space. |
| 841 void OnFileDownloadedAndSpaceChecked( | 846 void OnFileDownloadedAndSpaceChecked( |
| 842 const GetFileFromCacheParams& params, | 847 const GetFileFromCacheParams& params, |
| 843 GDataErrorCode status, | 848 GDataErrorCode status, |
| 844 const GURL& content_url, | 849 const GURL& content_url, |
| 845 const FilePath& downloaded_file_path, | 850 const FilePath& downloaded_file_path, |
| 846 bool* has_enough_space); | 851 bool* has_enough_space); |
| 847 | 852 |
| 848 // Callback for handling internal StoreToCache() calls after downloading | 853 // Callback for handling internal StoreToCache() calls after downloading |
| (...skipping 633 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1482 | 1487 |
| 1483 ObserverList<Observer> observers_; | 1488 ObserverList<Observer> observers_; |
| 1484 | 1489 |
| 1485 // The token is used to post tasks to the blocking pool in sequence. | 1490 // The token is used to post tasks to the blocking pool in sequence. |
| 1486 const base::SequencedWorkerPool::SequenceToken sequence_token_; | 1491 const base::SequencedWorkerPool::SequenceToken sequence_token_; |
| 1487 }; | 1492 }; |
| 1488 | 1493 |
| 1489 } // namespace gdata | 1494 } // namespace gdata |
| 1490 | 1495 |
| 1491 #endif // CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_H_ | 1496 #endif // CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_H_ |
| OLD | NEW |