Commit 3aec17e2 authored by tedchoc@chromium.org's avatar tedchoc@chromium.org

Make about:version android friendly.

- Moved CSS into shared/css similar to other about pages.
  (cleaned up style warnings during move).
- Added android specific CSS overrides where necessary.
- Removed flash section as it is not supported on Android.

BUG=
TEST=


Review URL: https://chromiumcodereview.appspot.com/10821026

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@148661 0039d316-1c4b-4281-b951-d872f2087c98
parent c92f4b45
...@@ -7,64 +7,15 @@ about:version template page ...@@ -7,64 +7,15 @@ about:version template page
<html id="t" i18n-values="dir:textdirection;"> <html id="t" i18n-values="dir:textdirection;">
<head> <head>
<title i18n-content="title"></title> <title i18n-content="title"></title>
<style> <if expr="pp_ifdef('android')">
body { <meta name="viewport" content="width=device-width"/>
font-family:Helvetica,Arial,sans-serif; </if>
background-color:white; <link rel="stylesheet" href="shared/css/about_version.css">
color: black; <if expr="pp_ifdef('android')">
margin: 0px; <link rel="stylesheet" href="about_version_android.css">
} </if>
#outer { <script src="chrome://version/version.js"></script>
margin-top: 10px; <script src="chrome://version/strings.js"></script>
margin-left: auto;
margin-right: auto;
width: 800px;
}
#inner {
padding-top: 10px;
width: 550px;
}
.label {
-webkit-padding-end: 5px;
font-size: 0.9em;
font-weight: bold;
text-align: end;
white-space: nowrap;
}
.label:after {
content: ":";
}
#logo {
text-align: right;
float: right;
width: 180px;
margin-left: 40px;
}
#logo-img {
/* TODO: Remove once http://crbug.com/135179 is fixed */
content: url('chrome://theme/IDR_PRODUCT_LOGO');
}
#company {
text-align: right;
font-size: 0.7em;
}
#copyright {
text-align: right;
font-size: 0.7em;
}
#name {
}
#useragent {
font-family: monospace;
}
.version {
font-family: monospace;
padding-left: 5px;
max-width: 430px;
}
</style>
<script src="chrome://version/version.js"></script>
<script src="chrome://version/strings.js"></script>
</head> </head>
<body> <body>
...@@ -94,9 +45,11 @@ about:version template page ...@@ -94,9 +45,11 @@ about:version template page
<tr><td class="label" valign="top">JavaScript</td> <tr><td class="label" valign="top">JavaScript</td>
<td class="version" id="js_engine"><span i18n-content="js_engine"></span> <span i18n-content="js_version"></span></td> <td class="version" id="js_engine"><span i18n-content="js_engine"></span> <span i18n-content="js_version"></span></td>
</tr> </tr>
<if expr="not pp_ifdef('android')">
<tr><td class="label" valign="top" i18n-content="flash_plugin"></td> <tr><td class="label" valign="top" i18n-content="flash_plugin"></td>
<td class="version" id="flash_version" i18n-content="flash_version"></td> <td class="version" id="flash_version" i18n-content="flash_version"></td>
</tr> </tr>
</if>
<tr><td class="label" valign="top" i18n-content="user_agent_name"></td> <tr><td class="label" valign="top" i18n-content="user_agent_name"></td>
<td class="version" id="useragent" i18n-content="useragent"></td> <td class="version" id="useragent" i18n-content="useragent"></td>
</tr> </tr>
......
/* Copyright (c) 2012 The Chromium Authors. All rights reserved.
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file. */
#outer {
text-align: left;
width: 90%;
}
#inner {
width: auto;
}
#logo {
float: none;
margin-left: auto;
margin-right: auto;
}
#logo-img {
/* Android does not support themes and can not use IDR_PRODUCT_LOGO. */
content:
url(../../app/theme/default_100_percent/%DISTRIBUTION%/product_logo.png);
}
/* Copyright (c) 2012 The Chromium Authors. All rights reserved.
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file. */
body {
background-color: white;
color: black;
font-family: Helvetica,Arial,sans-serif;
margin: 0;
}
#outer {
margin-left: auto;
margin-right: auto;
margin-top: 10px;
width: 800px;
}
#inner {
padding-top: 10px;
width: 550px;
}
.label {
-webkit-padding-end: 5px;
font-size: 0.9em;
font-weight: bold;
text-align: end;
white-space: nowrap;
}
.label:after {
content: ':';
}
#logo {
float: right;
margin-left: 40px;
text-align: right;
width: 180px;
}
#logo-img {
/* TODO: Remove once http://crbug.com/135179 is fixed */
content: url('chrome://theme/IDR_PRODUCT_LOGO');
}
#company {
font-size: 0.7em;
text-align: right;
}
#copyright {
font-size: 0.7em;
text-align: right;
}
#useragent {
font-family: monospace;
}
.version {
font-family: monospace;
max-width: 430px;
padding-left: 5px;
}
...@@ -1025,6 +1025,7 @@ std::string AboutVersionStrings(DictionaryValue* localized_strings, ...@@ -1025,6 +1025,7 @@ std::string AboutVersionStrings(DictionaryValue* localized_strings,
localized_strings->SetString("js_engine", "V8"); localized_strings->SetString("js_engine", "V8");
localized_strings->SetString("js_version", v8::V8::GetVersion()); localized_strings->SetString("js_version", v8::V8::GetVersion());
#if !defined(OS_ANDROID)
// Obtain the version of the first enabled Flash plugin. // Obtain the version of the first enabled Flash plugin.
std::vector<webkit::WebPluginInfo> info_array; std::vector<webkit::WebPluginInfo> info_array;
PluginService::GetInstance()->GetPluginInfoArray( PluginService::GetInstance()->GetPluginInfoArray(
...@@ -1042,6 +1043,7 @@ std::string AboutVersionStrings(DictionaryValue* localized_strings, ...@@ -1042,6 +1043,7 @@ std::string AboutVersionStrings(DictionaryValue* localized_strings,
} }
localized_strings->SetString("flash_plugin", "Flash"); localized_strings->SetString("flash_plugin", "Flash");
localized_strings->SetString("flash_version", flash_version); localized_strings->SetString("flash_version", flash_version);
#endif
localized_strings->SetString("company", localized_strings->SetString("company",
l10n_util::GetStringUTF16(IDS_ABOUT_VERSION_COMPANY_NAME)); l10n_util::GetStringUTF16(IDS_ABOUT_VERSION_COMPANY_NAME));
localized_strings->SetString("copyright", localized_strings->SetString("copyright",
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment