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

Unified Diff: chrome/browser/chromeos/app_mode/kiosk_app_update_service.cc

Issue 137343003: kiosk: Do update check during launch. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: for #1 comments, use default for empty update url and skip for bad update url Created 6 years, 11 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/app_mode/kiosk_app_update_service.cc
diff --git a/chrome/browser/chromeos/app_mode/kiosk_app_update_service.cc b/chrome/browser/chromeos/app_mode/kiosk_app_update_service.cc
index f96eab155d3a98bac57e6e24b6e7d7480a0c87a7..9b2763158b89616cda3c5aaf548a64cd0b212f44 100644
--- a/chrome/browser/chromeos/app_mode/kiosk_app_update_service.cc
+++ b/chrome/browser/chromeos/app_mode/kiosk_app_update_service.cc
@@ -8,6 +8,7 @@
#include "chrome/browser/app_mode/app_mode_utils.h"
#include "chrome/browser/browser_process.h"
#include "chrome/browser/browser_process_platform_part_chromeos.h"
+#include "chrome/browser/chromeos/app_mode/kiosk_app_manager.h"
#include "chrome/browser/chromeos/system/automatic_reboot_manager.h"
#include "chrome/browser/extensions/api/runtime/runtime_api.h"
#include "chrome/browser/extensions/extension_service.h"
@@ -71,6 +72,12 @@ void KioskAppUpdateService::OnAppUpdateAvailable(
if (extension->id() != app_id_)
return;
+ // Clears cached app data so that it will be reloaded if update from app
+ // does not finish in this run.
+ KioskAppManager::Get()->ClearAppData(app_id_);
+ KioskAppManager::Get()->UpdateAppDataFromProfile(
+ app_id_, profile_, extension);
+
extensions::RuntimeEventRouter::DispatchOnRestartRequiredEvent(
profile_,
app_id_,

Powered by Google App Engine
This is Rietveld 408576698