Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3)

Side by Side Diff: chrome/browser/chromeos/gdata/gdata_file_system.h

Issue 10826006: gdata: File info of dirty files should be get from the cached file. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rename Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/chromeos/gdata/gdata_file_system.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_GDATA_GDATA_FILE_SYSTEM_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_H_
6 #define CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_H_ 6 #define CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_H_
7 7
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 837 matching lines...) Expand 10 before | Expand all | Expand 10 after
848 GDataFileError error, 848 GDataFileError error,
849 scoped_ptr<GDataEntryProto> entry_proto); 849 scoped_ptr<GDataEntryProto> entry_proto);
850 850
851 // Part of RequestDirectoryRefreshOnUIThread(). Called after 851 // Part of RequestDirectoryRefreshOnUIThread(). Called after
852 // GetEntryInfoByPath() is complete. 852 // GetEntryInfoByPath() is complete.
853 void RequestDirectoryRefreshOnUIThreadAfterGetEntryInfo( 853 void RequestDirectoryRefreshOnUIThreadAfterGetEntryInfo(
854 const FilePath& file_path, 854 const FilePath& file_path,
855 GDataFileError error, 855 GDataFileError error,
856 scoped_ptr<GDataEntryProto> entry_proto); 856 scoped_ptr<GDataEntryProto> entry_proto);
857 857
858 // Part of GetEntryByResourceId and GetEntryByPath. Checks whether there is a
859 // local dirty cache for the entry, and if there is, replace the
860 // PlatformFileInfo part of the |entry_proto| with the locally modified info.
861 void CheckLocalModificationAndRun(scoped_ptr<GDataEntryProto> entry_proto,
862 const GetEntryInfoCallback& callback);
863 void CheckLocalModificationAndRunAfterGetCacheEntry(
864 scoped_ptr<GDataEntryProto> entry_proto,
865 const GetEntryInfoCallback& callback,
866 bool success,
867 const GDataCacheEntry& cache_entry);
868 void CheckLocalModificationAndRunAfterGetCacheFile(
869 scoped_ptr<GDataEntryProto> entry_proto,
870 const GetEntryInfoCallback& callback,
871 GDataFileError error,
872 const std::string& resource_id,
873 const std::string& md5,
874 const FilePath& local_cache_path);
875 void CheckLocalModificationAndRunAfterGetFileInfo(
876 scoped_ptr<GDataEntryProto> entry_proto,
877 const GetEntryInfoCallback& callback,
878 base::PlatformFileInfo* file_info,
879 bool* get_file_info_result);
880
858 // All members should be accessed only on UI thread. Do not post tasks to 881 // All members should be accessed only on UI thread. Do not post tasks to
859 // other threads with base::Unretained(this). 882 // other threads with base::Unretained(this).
860 scoped_ptr<GDataDirectoryService> directory_service_; 883 scoped_ptr<GDataDirectoryService> directory_service_;
861 884
862 // The profile hosts the GDataFileSystem via GDataSystemService. 885 // The profile hosts the GDataFileSystem via GDataSystemService.
863 Profile* profile_; 886 Profile* profile_;
864 887
865 // The cache owned by GDataSystemService. 888 // The cache owned by GDataSystemService.
866 GDataCache* cache_; 889 GDataCache* cache_;
867 890
(...skipping 22 matching lines...) Expand all
890 base::WeakPtr<GDataFileSystem> ui_weak_ptr_; 913 base::WeakPtr<GDataFileSystem> ui_weak_ptr_;
891 914
892 ObserverList<Observer> observers_; 915 ObserverList<Observer> observers_;
893 916
894 scoped_refptr<base::SequencedTaskRunner> blocking_task_runner_; 917 scoped_refptr<base::SequencedTaskRunner> blocking_task_runner_;
895 }; 918 };
896 919
897 } // namespace gdata 920 } // namespace gdata
898 921
899 #endif // CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_H_ 922 #endif // CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/chromeos/gdata/gdata_file_system.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698