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

Unified Diff: chrome/browser/ui/webui/options/about_page_handler.cc

Issue 6883142: Show ChromeOS bios firmware in about dialog. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 9 years, 8 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
« no previous file with comments | « chrome/browser/ui/webui/options/about_page_handler.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/options/about_page_handler.cc
===================================================================
--- chrome/browser/ui/webui/options/about_page_handler.cc (revision 82505)
+++ chrome/browser/ui/webui/options/about_page_handler.cc (working copy)
@@ -108,6 +108,7 @@
static OptionsStringResource resources[] = {
#if defined (OS_CHROMEOS)
+ { "firmware", IDS_ABOUT_PAGE_FIRMWARE },
{ "product", IDS_PRODUCT_OS_NAME },
{ "os", IDS_PRODUCT_OS_NAME },
{ "loading", IDS_ABOUT_PAGE_LOADING },
@@ -275,6 +276,8 @@
loader_.GetVersion(&consumer_,
NewCallback(this, &AboutPageHandler::OnOSVersion),
chromeos::VersionLoader::VERSION_FULL);
+ loader_.GetFirmware(&consumer_,
+ NewCallback(this, &AboutPageHandler::OnOSFirmware));
chromeos::UpdateLibrary* update_library =
chromeos::CrosLibrary::Get()->GetUpdateLibrary();
@@ -419,6 +422,15 @@
}
}
+void AboutPageHandler::OnOSFirmware(chromeos::VersionLoader::Handle handle,
+ std::string firmware) {
+ if (firmware.size()) {
+ scoped_ptr<Value> firmware_string(Value::CreateStringValue(firmware));
+ web_ui_->CallJavascriptFunction("AboutPage.updateOSFirmwareCallback",
+ *firmware_string);
+ }
+}
+
// Callback from UpdateEngine with channel information.
// static
void AboutPageHandler::UpdateSelectedChannel(void* user_data,
« no previous file with comments | « chrome/browser/ui/webui/options/about_page_handler.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698