Chromium Code Reviews| 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_EXTENSIONS_FILE_BROWSER_PRIVATE_API_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_BROWSER_PRIVATE_API_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_BROWSER_PRIVATE_API_H_ | 6 #define CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_BROWSER_PRIVATE_API_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <queue> | 10 #include <queue> |
| (...skipping 258 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 269 | 269 |
| 270 AddMountFunction(); | 270 AddMountFunction(); |
| 271 | 271 |
| 272 protected: | 272 protected: |
| 273 virtual ~AddMountFunction(); | 273 virtual ~AddMountFunction(); |
| 274 | 274 |
| 275 // AsyncExtensionFunction overrides. | 275 // AsyncExtensionFunction overrides. |
| 276 virtual bool RunImpl() OVERRIDE; | 276 virtual bool RunImpl() OVERRIDE; |
| 277 | 277 |
| 278 private: | 278 private: |
| 279 // Sends gdata mount event to renderers. | |
| 280 void RaiseGDataMountEvent(gdata::GDataErrorCode error); | |
| 281 // A callback method to handle the result of GData authentication request. | |
| 282 void OnGDataAuthentication(gdata::GDataErrorCode error, | |
| 283 const std::string& token); | |
| 284 // A callback method to handle the result of | 279 // A callback method to handle the result of |
| 285 // GetLocalPathsOnFileThreadAndRunCallbackOnUIThread. | 280 // GetLocalPathsOnFileThreadAndRunCallbackOnUIThread. |
| 286 void GetLocalPathsResponseOnUIThread(const std::string& mount_type_str, | 281 void GetLocalPathsResponseOnUIThread(const std::string& mount_type_str, |
| 287 const SelectedFileInfoList& files); | 282 const SelectedFileInfoList& files); |
| 288 // A callback method to handle the result of SetMountedState. | 283 // A callback method to handle the result of SetMountedState. |
| 289 void OnMountedStateSet(const std::string& mount_type, | 284 void OnMountedStateSet(const std::string& mount_type, |
| 290 const FilePath::StringType& file_name, | 285 const FilePath::StringType& file_name, |
| 291 gdata::GDataFileError error, | 286 gdata::GDataFileError error, |
| 292 const FilePath& file_path); | 287 const FilePath& file_path); |
| 288 | |
| 289 base::WeakPtrFactory<AddMountFunction> weak_ptr_factory_; | |
|
satorux1
2012/08/03 17:28:56
I think we don't need this. We don't need this. Ex
yoshiki
2012/08/03 18:15:08
Done.
| |
| 293 }; | 290 }; |
| 294 | 291 |
| 295 // Unmounts selected device. Expects mount point path as an argument. | 292 // Unmounts selected device. Expects mount point path as an argument. |
| 296 class RemoveMountFunction : public FileBrowserFunction { | 293 class RemoveMountFunction : public FileBrowserFunction { |
| 297 public: | 294 public: |
| 298 DECLARE_EXTENSION_FUNCTION_NAME("fileBrowserPrivate.removeMount"); | 295 DECLARE_EXTENSION_FUNCTION_NAME("fileBrowserPrivate.removeMount"); |
| 299 | 296 |
| 300 RemoveMountFunction(); | 297 RemoveMountFunction(); |
| 301 | 298 |
| 302 protected: | 299 protected: |
| (...skipping 390 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 693 DECLARE_EXTENSION_FUNCTION_NAME( | 690 DECLARE_EXTENSION_FUNCTION_NAME( |
| 694 "fileBrowserPrivate.requestDirectoryRefresh"); | 691 "fileBrowserPrivate.requestDirectoryRefresh"); |
| 695 | 692 |
| 696 protected: | 693 protected: |
| 697 virtual ~RequestDirectoryRefreshFunction() {} | 694 virtual ~RequestDirectoryRefreshFunction() {} |
| 698 | 695 |
| 699 virtual bool RunImpl() OVERRIDE; | 696 virtual bool RunImpl() OVERRIDE; |
| 700 }; | 697 }; |
| 701 | 698 |
| 702 #endif // CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_BROWSER_PRIVATE_API_H_ | 699 #endif // CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_BROWSER_PRIVATE_API_H_ |
| OLD | NEW |