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

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

Issue 10834115: Drive: Mount/Unmount GoogleDrive on Files App when the file system is mounted/unmounted. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Add a comment. 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
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 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 virtual void RequestDirectoryRefresh( 110 virtual void RequestDirectoryRefresh(
111 const FilePath& file_path) OVERRIDE; 111 const FilePath& file_path) OVERRIDE;
112 virtual void GetAvailableSpace( 112 virtual void GetAvailableSpace(
113 const GetAvailableSpaceCallback& callback) OVERRIDE; 113 const GetAvailableSpaceCallback& callback) OVERRIDE;
114 virtual void AddUploadedFile(UploadMode upload_mode, 114 virtual void AddUploadedFile(UploadMode upload_mode,
115 const FilePath& virtual_dir_path, 115 const FilePath& virtual_dir_path,
116 scoped_ptr<DocumentEntry> entry, 116 scoped_ptr<DocumentEntry> entry,
117 const FilePath& file_content_path, 117 const FilePath& file_content_path,
118 GDataCache::FileOperationType cache_operation, 118 GDataCache::FileOperationType cache_operation,
119 const base::Closure& callback) OVERRIDE; 119 const base::Closure& callback) OVERRIDE;
120 virtual void AddDriveMountPoint() OVERRIDE;
121 virtual void RemoveDriveMountPoint() OVERRIDE;
120 122
121 // content::NotificationObserver implementation. 123 // content::NotificationObserver implementation.
122 virtual void Observe(int type, 124 virtual void Observe(int type,
123 const content::NotificationSource& source, 125 const content::NotificationSource& source,
124 const content::NotificationDetails& details) OVERRIDE; 126 const content::NotificationDetails& details) OVERRIDE;
125 127
126 // Used in tests to load the root feed from the cache. 128 // Used in tests to load the root feed from the cache.
127 void LoadRootFeedFromCacheForTesting(); 129 void LoadRootFeedFromCacheForTesting();
128 130
129 private: 131 private:
(...skipping 522 matching lines...) Expand 10 before | Expand all | Expand 10 after
652 654
653 // Callback for handling root directory refresh from the cache. 655 // Callback for handling root directory refresh from the cache.
654 void OnProtoLoaded(LoadRootFeedParams* params); 656 void OnProtoLoaded(LoadRootFeedParams* params);
655 657
656 // Save filesystem as proto file. 658 // Save filesystem as proto file.
657 void SaveFileSystemAsProto(); 659 void SaveFileSystemAsProto();
658 660
659 // Notifies events to observers on UI thread. 661 // Notifies events to observers on UI thread.
660 void NotifyDirectoryChanged(const FilePath& directory_path); 662 void NotifyDirectoryChanged(const FilePath& directory_path);
661 void NotifyDocumentFeedFetched(int num_accumulated_entries); 663 void NotifyDocumentFeedFetched(int num_accumulated_entries);
664 void NotifyFileSystemMounted();
665 void NotifyFileSystemUnmounting();
662 666
663 // Runs the callback and notifies that the initial load is finished. 667 // Runs the callback and notifies that the initial load is finished.
664 void RunAndNotifyInitialLoadFinished( 668 void RunAndNotifyInitialLoadFinished(
665 const FindEntryCallback& callback, 669 const FindEntryCallback& callback,
666 GDataFileError error, 670 GDataFileError error,
667 GDataEntry* entry); 671 GDataEntry* entry);
668 672
669 // Helper function that completes bookkeeping tasks related to 673 // Helper function that completes bookkeeping tasks related to
670 // completed file transfer. 674 // completed file transfer.
671 void OnTransferCompleted( 675 void OnTransferCompleted(
(...skipping 258 matching lines...) Expand 10 before | Expand all | Expand 10 after
930 base::WeakPtr<GDataFileSystem> ui_weak_ptr_; 934 base::WeakPtr<GDataFileSystem> ui_weak_ptr_;
931 935
932 ObserverList<Observer> observers_; 936 ObserverList<Observer> observers_;
933 937
934 scoped_refptr<base::SequencedTaskRunner> blocking_task_runner_; 938 scoped_refptr<base::SequencedTaskRunner> blocking_task_runner_;
935 }; 939 };
936 940
937 } // namespace gdata 941 } // namespace gdata
938 942
939 #endif // CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_H_ 943 #endif // CHROME_BROWSER_CHROMEOS_GDATA_GDATA_FILE_SYSTEM_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698