Index: chrome/browser/chromeos/extensions/file_browser_private_api.h |
diff --git a/chrome/browser/chromeos/extensions/file_browser_private_api.h b/chrome/browser/chromeos/extensions/file_browser_private_api.h |
index ea88ebf1c893cefe8040406bf43c67ffb1e99133..4d4b8bba268c1cfdec8cf78827d8412b73435b5b 100644 |
--- a/chrome/browser/chromeos/extensions/file_browser_private_api.h |
+++ b/chrome/browser/chromeos/extensions/file_browser_private_api.h |
@@ -57,12 +57,12 @@ class FileBrowserPrivateAPI : public ProfileKeyedService { |
// Convenience function to return the FileBrowserPrivateAPI for a Profile. |
static FileBrowserPrivateAPI* Get(Profile* profile); |
- scoped_refptr<FileBrowserEventRouter> event_router() { |
- return event_router_; |
+ FileBrowserEventRouter* event_router() { |
+ return event_router_.get(); |
} |
private: |
- scoped_refptr<FileBrowserEventRouter> event_router_; |
+ scoped_ptr<FileBrowserEventRouter> event_router_; |
}; |
// Implements the chrome.fileBrowserPrivate.logoutUser method. |
@@ -107,20 +107,16 @@ class FileWatchBrowserFunctionBase : public AsyncExtensionFunction { |
protected: |
virtual ~FileWatchBrowserFunctionBase() {} |
- virtual bool PerformFileWatchOperation( |
- scoped_refptr<FileBrowserEventRouter> event_router, |
- const base::FilePath& local_path, const base::FilePath& virtual_path, |
+ virtual void PerformFileWatchOperation( |
+ const base::FilePath& local_path, |
+ const base::FilePath& virtual_path, |
const std::string& extension_id) = 0; |
// AsyncExtensionFunction overrides. |
virtual bool RunImpl() OVERRIDE; |
- private: |
- void RespondOnUIThread(bool success); |
- void RunFileWatchOperationOnFileThread( |
- scoped_refptr<FileBrowserEventRouter> event_router, |
- const fileapi::FileSystemURL& file_url, |
- const std::string& extension_id); |
+ // Calls SendResponse() with |success| converted to base::Value. |
+ void Respond(bool success); |
}; |
// Implements the chrome.fileBrowserPrivate.addFileWatch method. |
@@ -132,9 +128,9 @@ class AddFileWatchBrowserFunction : public FileWatchBrowserFunctionBase { |
protected: |
virtual ~AddFileWatchBrowserFunction() {} |
- virtual bool PerformFileWatchOperation( |
- scoped_refptr<FileBrowserEventRouter> event_router, |
- const base::FilePath& local_path, const base::FilePath& virtual_path, |
+ virtual void PerformFileWatchOperation( |
+ const base::FilePath& local_path, |
+ const base::FilePath& virtual_path, |
const std::string& extension_id) OVERRIDE; |
}; |
@@ -148,9 +144,9 @@ class RemoveFileWatchBrowserFunction : public FileWatchBrowserFunctionBase { |
protected: |
virtual ~RemoveFileWatchBrowserFunction() {} |
- virtual bool PerformFileWatchOperation( |
- scoped_refptr<FileBrowserEventRouter> event_router, |
- const base::FilePath& local_path, const base::FilePath& virtual_path, |
+ virtual void PerformFileWatchOperation( |
+ const base::FilePath& local_path, |
+ const base::FilePath& virtual_path, |
const std::string& extension_id) OVERRIDE; |
}; |