| 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_DRIVE_SYNC_CLIENT_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_DRIVE_SYNC_CLIENT_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_DRIVE_SYNC_CLIENT_H_ | 6 #define CHROME_BROWSER_CHROMEOS_DRIVE_SYNC_CLIENT_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 124 void OnRemove(const std::string& resource_id, FileError error); | 124 void OnRemove(const std::string& resource_id, FileError error); |
| 125 | 125 |
| 126 // Called when a file is pinned. | 126 // Called when a file is pinned. |
| 127 void OnPinned(const std::string& resource_id, FileError error); | 127 void OnPinned(const std::string& resource_id, FileError error); |
| 128 | 128 |
| 129 // Called when the file for |resource_id| is fetched. | 129 // Called when the file for |resource_id| is fetched. |
| 130 // Calls DoSyncLoop() to go back to the sync loop. | 130 // Calls DoSyncLoop() to go back to the sync loop. |
| 131 void OnFetchFileComplete(const std::string& resource_id, | 131 void OnFetchFileComplete(const std::string& resource_id, |
| 132 FileError error, | 132 FileError error, |
| 133 const base::FilePath& local_path, | 133 const base::FilePath& local_path, |
| 134 const std::string& ununsed_mime_type, | 134 scoped_ptr<ResourceEntry> entry); |
| 135 DriveFileType file_type); | |
| 136 | 135 |
| 137 // Called when the file for |resource_id| is uploaded. | 136 // Called when the file for |resource_id| is uploaded. |
| 138 // Calls DoSyncLoop() to go back to the sync loop. | 137 // Calls DoSyncLoop() to go back to the sync loop. |
| 139 void OnUploadFileComplete(const std::string& resource_id, | 138 void OnUploadFileComplete(const std::string& resource_id, |
| 140 FileError error); | 139 FileError error); |
| 141 | 140 |
| 142 FileSystemInterface* file_system_; // Owned by DriveSystemService. | 141 FileSystemInterface* file_system_; // Owned by DriveSystemService. |
| 143 internal::FileCache* cache_; // Owned by DriveSystemService. | 142 internal::FileCache* cache_; // Owned by DriveSystemService. |
| 144 | 143 |
| 145 // List of the resource ids of resources which have a fetch task created. | 144 // List of the resource ids of resources which have a fetch task created. |
| (...skipping 12 matching lines...) Expand all Loading... |
| 158 // Note: This should remain the last member so it'll be destroyed and | 157 // Note: This should remain the last member so it'll be destroyed and |
| 159 // invalidate its weak pointers before any other members are destroyed. | 158 // invalidate its weak pointers before any other members are destroyed. |
| 160 base::WeakPtrFactory<SyncClient> weak_ptr_factory_; | 159 base::WeakPtrFactory<SyncClient> weak_ptr_factory_; |
| 161 | 160 |
| 162 DISALLOW_COPY_AND_ASSIGN(SyncClient); | 161 DISALLOW_COPY_AND_ASSIGN(SyncClient); |
| 163 }; | 162 }; |
| 164 | 163 |
| 165 } // namespace drive | 164 } // namespace drive |
| 166 | 165 |
| 167 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_SYNC_CLIENT_H_ | 166 #endif // CHROME_BROWSER_CHROMEOS_DRIVE_SYNC_CLIENT_H_ |
| OLD | NEW |