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

Unified Diff: chrome/browser/chromeos/extensions/file_browser_private_api.cc

Issue 10386226: gdata: Add requestDirectoryRefresh to file_browser_private. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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/extensions/file_browser_private_api.cc
diff --git a/chrome/browser/chromeos/extensions/file_browser_private_api.cc b/chrome/browser/chromeos/extensions/file_browser_private_api.cc
index 825bc6908abb0e1b20fca5bd0c561e0fdcd7aa66..a1a72efe948c6ed5e829737c04a381c7cb85aebc 100644
--- a/chrome/browser/chromeos/extensions/file_browser_private_api.cc
+++ b/chrome/browser/chromeos/extensions/file_browser_private_api.cc
@@ -2128,3 +2128,20 @@ bool GetNetworkConnectionStateFunction::RunImpl() {
return true;
}
+
+bool RequestDirectoryRefreshFunction::RunImpl() {
+ std::string file_url_as_string;
tbarzic 2012/05/18 22:51:12 what if the file is under /gdata/.search/foo/file.
tbarzic 2012/05/18 22:56:13 Alternatively, you could use GetPathForDriveSearch
satorux1 2012/05/18 23:42:19 Per off-line discussion, added a check in GDataFil
+ if (!args_->GetString(0, &file_url_as_string))
+ return false;
+
+ gdata::GDataSystemService* system_service =
+ gdata::GDataSystemServiceFactory::GetForProfile(profile_);
+ if (!system_service || !system_service->file_system())
+ return false;
+
+ FilePath directory_path = GetVirtualPathFromURL(GURL(file_url_as_string));
tbarzic 2012/05/18 22:51:12 extra space after =
satorux1 2012/05/18 23:42:19 Done.
+ system_service->file_system()->RequestDirectoryRefresh(
+ directory_path);
tbarzic 2012/05/18 22:51:12 can't this feed in former line
satorux1 2012/05/18 23:42:19 Done.
+
+ return true;
+}

Powered by Google App Engine
This is Rietveld 408576698