diff options
author | yoz@chromium.org <yoz@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-08-03 22:57:43 +0000 |
---|---|---|
committer | yoz@chromium.org <yoz@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-08-03 22:57:43 +0000 |
commit | 5806150245765654705eec1736d99ed797d074ec (patch) | |
tree | b33d32f3e2de65a67218a1f08894bd2c280f1026 /chrome/browser/automation | |
parent | 29ce8a20147c4051f28480819e98f3740f51676f (diff) | |
download | chromium_src-5806150245765654705eec1736d99ed797d074ec.zip chromium_src-5806150245765654705eec1736d99ed797d074ec.tar.gz chromium_src-5806150245765654705eec1736d99ed797d074ec.tar.bz2 |
Reland 'Show crashed apps on NTP, desaturated. Click to reload.'
Refactor CreateAppInfo less, since pyauto functional tests for the NTP expect it to still return something for special apps like the Webstore.
original CL at http://codereview.chromium.org/7517019
reverted CL at http://codereview.chromium.org/7553001
BUG=90433
TEST=Crash a packaged app with a background page. It appears on the NTP, and clicking its icon relaunches it. ntp pyauto functional tests also pass.
Review URL: http://codereview.chromium.org/7542027
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@95348 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/automation')
-rw-r--r-- | chrome/browser/automation/automation_provider_observers.cc | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/chrome/browser/automation/automation_provider_observers.cc b/chrome/browser/automation/automation_provider_observers.cc index 155af6c..63cbdd2 100644 --- a/chrome/browser/automation/automation_provider_observers.cc +++ b/chrome/browser/automation/automation_provider_observers.cc @@ -2064,6 +2064,17 @@ NTPInfoObserver::NTPInfoObserver( apps_list->Append(*app); } delete disabled_apps; + // Process terminated extensions. + const ExtensionList* terminated_extensions = + ext_service->terminated_extensions(); + std::vector<DictionaryValue*>* terminated_apps = GetAppInfoFromExtensions( + terminated_extensions, ext_service); + for (std::vector<DictionaryValue*>::const_iterator app = + terminated_apps->begin(); app != terminated_apps->end(); ++app) { + (*app)->SetBoolean("is_disabled", true); + apps_list->Append(*app); + } + delete terminated_apps; ntp_info_->Set("apps", apps_list); // Get the info that would be displayed in the recently closed section. |