| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_SYSTEM_PROVIDER_FILE_SYSTEM_PROV
IDER_API_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_SYSTEM_PROVIDER_FILE_SYSTEM_PROV
IDER_API_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_SYSTEM_PROVIDER_FILE_SYSTEM_PROV
IDER_API_H_ | 6 #define CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_SYSTEM_PROVIDER_FILE_SYSTEM_PROV
IDER_API_H_ |
| 7 | 7 |
| 8 #include "chrome/browser/chromeos/extensions/file_system_provider/provider_funct
ion.h" | 8 #include "chrome/browser/chromeos/extensions/file_system_provider/provider_funct
ion.h" |
| 9 #include "chrome/browser/extensions/chrome_extension_function.h" | 9 #include "chrome/browser/extensions/chrome_extension_function.h" |
| 10 | 10 |
| (...skipping 22 matching lines...) Expand all Loading... |
| 33 class FileSystemProviderGetAllFunction : public ChromeSyncExtensionFunction { | 33 class FileSystemProviderGetAllFunction : public ChromeSyncExtensionFunction { |
| 34 public: | 34 public: |
| 35 DECLARE_EXTENSION_FUNCTION("fileSystemProvider.getAll", | 35 DECLARE_EXTENSION_FUNCTION("fileSystemProvider.getAll", |
| 36 FILESYSTEMPROVIDER_GETALL) | 36 FILESYSTEMPROVIDER_GETALL) |
| 37 | 37 |
| 38 protected: | 38 protected: |
| 39 virtual ~FileSystemProviderGetAllFunction() {} | 39 virtual ~FileSystemProviderGetAllFunction() {} |
| 40 virtual bool RunSync() override; | 40 virtual bool RunSync() override; |
| 41 }; | 41 }; |
| 42 | 42 |
| 43 class FileSystemProviderNotifyFunction : public ChromeSyncExtensionFunction { | 43 class FileSystemProviderNotifyFunction : public ChromeAsyncExtensionFunction { |
| 44 public: | 44 public: |
| 45 DECLARE_EXTENSION_FUNCTION("fileSystemProvider.notify", | 45 DECLARE_EXTENSION_FUNCTION("fileSystemProvider.notify", |
| 46 FILESYSTEMPROVIDER_NOTIFY) | 46 FILESYSTEMPROVIDER_NOTIFY) |
| 47 | 47 |
| 48 protected: | 48 protected: |
| 49 virtual ~FileSystemProviderNotifyFunction() {} | 49 virtual ~FileSystemProviderNotifyFunction() {} |
| 50 virtual bool RunSync() override; | 50 virtual bool RunAsync() override; |
| 51 |
| 52 private: |
| 53 // Called when notifying is completed. |
| 54 void OnNotifyCompleted(base::File::Error result); |
| 51 }; | 55 }; |
| 52 | 56 |
| 53 class FileSystemProviderInternalUnmountRequestedSuccessFunction | 57 class FileSystemProviderInternalUnmountRequestedSuccessFunction |
| 54 : public FileSystemProviderInternalFunction { | 58 : public FileSystemProviderInternalFunction { |
| 55 public: | 59 public: |
| 56 DECLARE_EXTENSION_FUNCTION( | 60 DECLARE_EXTENSION_FUNCTION( |
| 57 "fileSystemProviderInternal.unmountRequestedSuccess", | 61 "fileSystemProviderInternal.unmountRequestedSuccess", |
| 58 FILESYSTEMPROVIDERINTERNAL_GETMETADATAREQUESTEDSUCCESS) | 62 FILESYSTEMPROVIDERINTERNAL_GETMETADATAREQUESTEDSUCCESS) |
| 59 | 63 |
| 60 protected: | 64 protected: |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 118 FILESYSTEMPROVIDERINTERNAL_OPERATIONREQUESTEDERROR) | 122 FILESYSTEMPROVIDERINTERNAL_OPERATIONREQUESTEDERROR) |
| 119 | 123 |
| 120 protected: | 124 protected: |
| 121 virtual ~FileSystemProviderInternalOperationRequestedErrorFunction() {} | 125 virtual ~FileSystemProviderInternalOperationRequestedErrorFunction() {} |
| 122 virtual bool RunWhenValid() override; | 126 virtual bool RunWhenValid() override; |
| 123 }; | 127 }; |
| 124 | 128 |
| 125 } // namespace extensions | 129 } // namespace extensions |
| 126 | 130 |
| 127 #endif // CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_SYSTEM_PROVIDER_FILE_SYSTEM_P
ROVIDER_API_H_ | 131 #endif // CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_SYSTEM_PROVIDER_FILE_SYSTEM_P
ROVIDER_API_H_ |
| OLD | NEW |