Chromium Code Reviews| Index: chrome/browser/chromeos/gdata/gdata_system_service.h |
| diff --git a/chrome/browser/chromeos/gdata/gdata_system_service.h b/chrome/browser/chromeos/gdata/gdata_system_service.h |
| index 070fa7718f69a685734624768f5d04ef599ca758..28d67c9a5fc5a507cfccc1cf179388f50e312aa8 100644 |
| --- a/chrome/browser/chromeos/gdata/gdata_system_service.h |
| +++ b/chrome/browser/chromeos/gdata/gdata_system_service.h |
| @@ -9,7 +9,9 @@ |
| #include "base/memory/scoped_ptr.h" |
| #include "base/memory/singleton.h" |
| +#include "base/memory/weak_ptr.h" |
| #include "base/threading/sequenced_worker_pool.h" |
| +#include "chrome/browser/chromeos/gdata/gdata_errorcode.h" |
| #include "chrome/browser/profiles/profile_keyed_service.h" |
| #include "chrome/browser/profiles/profile_keyed_service_factory.h" |
| @@ -41,6 +43,10 @@ class GDataSystemService : public ProfileKeyedService { |
| GDataContactsService* contacts_service() { return contacts_service_.get(); } |
| DriveWebAppsRegistry* webapps_registry() { return webapps_registry_.get(); } |
| + // Clears all the local cache files and resets cache-related information in |
| + // the memory. |
| + void ClearCache(const base::Callback<void(bool)>& callback); |
|
satorux1
2012/08/03 17:17:31
I changed my mind. I think we should give it a mor
yoshiki
2012/08/03 18:23:15
Done.
|
| + |
| // ProfileKeyedService override: |
| virtual void Shutdown() OVERRIDE; |
| @@ -58,6 +64,11 @@ class GDataSystemService : public ProfileKeyedService { |
| // Unregisters drive mount point from File API. |
| void RemoveDriveMountPoint(); |
| + // Adds back the drive mount point. Used to implement ClearCache(). |
| + void AddBackDriveMountPoint(const base::Callback<void(bool)>& callback, |
| + GDataFileError error, |
| + const FilePath& file_path); |
| + |
| friend class GDataSystemServiceFactory; |
| Profile* profile_; |
| @@ -70,6 +81,7 @@ class GDataSystemService : public ProfileKeyedService { |
| scoped_ptr<GDataDownloadObserver> download_observer_; |
| scoped_ptr<GDataSyncClient> sync_client_; |
| scoped_ptr<GDataContactsService> contacts_service_; |
| + base::WeakPtrFactory<GDataSystemService> weak_ptr_factory_; |
| DISALLOW_COPY_AND_ASSIGN(GDataSystemService); |
| }; |