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

Unified Diff: chrome/browser/android/webapk/webapk_install_service.cc

Issue 2933783002: [Android WebAPK] Change WebAPK update into two phases (Closed)
Patch Set: Created 3 years, 6 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/android/webapk/webapk_install_service.cc
diff --git a/chrome/browser/android/webapk/webapk_install_service.cc b/chrome/browser/android/webapk/webapk_install_service.cc
index 49c7b5da035a056052066384128ca390f0adc022..22dcbbeae941236cd6b8c7688427a80f1e0b2501 100644
--- a/chrome/browser/android/webapk/webapk_install_service.cc
+++ b/chrome/browser/android/webapk/webapk_install_service.cc
@@ -42,23 +42,14 @@ void WebApkInstallService::InstallAsync(const ShortcutInfo& shortcut_info,
}
void WebApkInstallService::UpdateAsync(
- const ShortcutInfo& shortcut_info,
- const SkBitmap& shortcut_icon,
const std::string& webapk_package,
- int webapk_version,
- const std::map<std::string, std::string>& icon_url_to_murmur2_hash,
- bool is_manifest_stale,
+ const GURL& start_url,
+ const base::string16& short_name,
+ std::unique_ptr<std::vector<uint8_t>> serialized_proto,
const FinishCallback& finish_callback) {
- DCHECK(!IsInstallInProgress(shortcut_info.manifest_url));
-
- installs_.insert(shortcut_info.manifest_url);
-
- WebApkInstaller::UpdateAsync(
- browser_context_, shortcut_info, shortcut_icon, webapk_package,
- webapk_version, icon_url_to_murmur2_hash, is_manifest_stale,
- base::Bind(&WebApkInstallService::OnFinishedInstall,
- weak_ptr_factory_.GetWeakPtr(), shortcut_info.manifest_url,
- finish_callback));
+ WebApkInstaller::UpdateAsync(browser_context_, webapk_package, start_url,
+ short_name, std::move(serialized_proto),
+ finish_callback);
}
void WebApkInstallService::OnFinishedInstall(

Powered by Google App Engine
This is Rietveld 408576698