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

Unified Diff: chrome/browser/chromeos/drive/file_system/update_operation.cc

Issue 15060002: drive: Rename FileCache methods in a blocking pool centric manner (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/chromeos/drive/file_system/update_operation.cc
diff --git a/chrome/browser/chromeos/drive/file_system/update_operation.cc b/chrome/browser/chromeos/drive/file_system/update_operation.cc
index 9cb8cffe6f934388f248371ae5f93e06a867ef92..99b42ba5ab2249ee9911046ef11af5aac02514d9 100644
--- a/chrome/browser/chromeos/drive/file_system/update_operation.cc
+++ b/chrome/browser/chromeos/drive/file_system/update_operation.cc
@@ -76,14 +76,15 @@ void UpdateOperation::UpdateFileByEntryInfo(
// Extract a pointer before we call Pass() so we can use it below.
ResourceEntry* entry_ptr = entry.get();
- cache_->GetFile(entry_ptr->resource_id(),
- entry_ptr->file_specific_info().file_md5(),
- base::Bind(&UpdateOperation::OnGetFileCompleteForUpdateFile,
- weak_ptr_factory_.GetWeakPtr(),
- context,
- callback,
- drive_file_path,
- base::Passed(&entry)));
+ cache_->GetFileOnUIThread(
+ entry_ptr->resource_id(),
+ entry_ptr->file_specific_info().file_md5(),
+ base::Bind(&UpdateOperation::OnGetFileCompleteForUpdateFile,
+ weak_ptr_factory_.GetWeakPtr(),
+ context,
+ callback,
+ drive_file_path,
+ base::Passed(&entry)));
}
void UpdateOperation::OnGetFileCompleteForUpdateFile(
@@ -155,9 +156,9 @@ void UpdateOperation::OnUpdatedFileRefreshed(
observer_->OnDirectoryChangedByOperation(drive_file_path.DirName());
// Clear the dirty bit if we have updated an existing file.
- cache_->ClearDirty(entry->resource_id(),
- entry->file_specific_info().file_md5(),
- callback);
+ cache_->ClearDirtyOnUIThread(entry->resource_id(),
+ entry->file_specific_info().file_md5(),
+ callback);
}
} // namespace file_system

Powered by Google App Engine
This is Rietveld 408576698