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

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

Issue 491403003: Update cached kiosk app crx from usb stick. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add back InformOwnerForDismiss in KioskExternalUpdateNotificationView. Created 6 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/chromeos/extensions/external_cache.cc
diff --git a/chrome/browser/chromeos/extensions/external_cache.cc b/chrome/browser/chromeos/extensions/external_cache.cc
index bd3c0413e4b2b203615fe0bcca9fe2707b13f0b1..4ec9fb5c336cd7adafa3e8e7a6ee597914eaa6bf 100644
--- a/chrome/browser/chromeos/extensions/external_cache.cc
+++ b/chrome/browser/chromeos/extensions/external_cache.cc
@@ -126,6 +126,20 @@ bool ExternalCache::GetExtension(const std::string& id,
return local_cache_.GetExtension(id, file_path, version);
}
+void ExternalCache::PutExternalExtension(
+ const std::string& id,
+ const base::FilePath& crx_file_path,
+ const std::string& version,
+ const PutExternalExtensionCallback& callback) {
+ local_cache_.PutExtension(id,
+ crx_file_path,
+ version,
+ base::Bind(&ExternalCache::OnPutExternalExtension,
+ weak_ptr_factory_.GetWeakPtr(),
+ id,
+ callback));
+}
+
void ExternalCache::Observe(int type,
const content::NotificationSource& source,
const content::NotificationDetails& details) {
@@ -321,6 +335,16 @@ void ExternalCache::OnPutExtension(const std::string& id,
UpdateExtensionLoader();
}
+void ExternalCache::OnPutExternalExtension(
+ const std::string& id,
+ const PutExternalExtensionCallback& callback,
+ const base::FilePath& file_path,
+ bool file_ownership_passed) {
+ DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
+ OnPutExtension(id, file_path, file_ownership_passed);
+ callback.Run(id, !file_ownership_passed);
+}
+
std::string ExternalCache::Delegate::GetInstalledExtensionVersion(
const std::string& id) {
return std::string();

Powered by Google App Engine
This is Rietveld 408576698