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

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

Issue 2933783002: [Android WebAPK] Change WebAPK update into two phases (Closed)
Patch Set: Merge branch 'master' into background_updates0 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 2c027b24ccea58f90f64db7c9e505eefa163f5ae..22dcbbeae941236cd6b8c7688427a80f1e0b2501 100644
--- a/chrome/browser/android/webapk/webapk_install_service.cc
+++ b/chrome/browser/android/webapk/webapk_install_service.cc
@@ -42,24 +42,14 @@ void WebApkInstallService::InstallAsync(const ShortcutInfo& shortcut_info,
}
void WebApkInstallService::UpdateAsync(
- const ShortcutInfo& shortcut_info,
- const SkBitmap& primary_icon,
- const SkBitmap& badge_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, primary_icon, badge_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(
« no previous file with comments | « chrome/browser/android/webapk/webapk_install_service.h ('k') | chrome/browser/android/webapk/webapk_installer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698