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

Unified Diff: chrome/browser/resources/options/chromeos_internet_options.js

Issue 6516019: Made activate/buy button show consistently on network list and details pages.... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 10 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/resources/options/chromeos_internet_options.js
===================================================================
--- chrome/browser/resources/options/chromeos_internet_options.js (revision 74823)
+++ chrome/browser/resources/options/chromeos_internet_options.js (working copy)
@@ -53,7 +53,7 @@
});
$('detailsInternetLogin').addEventListener('click', function(event) {
InternetOptions.loginFromDetails();
- });;
+ });
$('activateDetails').addEventListener('click', function(event) {
InternetOptions.activateFromDetails();
});
@@ -213,17 +213,27 @@
page.setAttribute('nocellplan', true);
page.removeAttribute('hascellplan');
}
- if (!data.needsPlan) {
+
+ if (!data.needsPlan)
page.setAttribute('hasactiveplan', true);
- } else {
+ else
page.removeAttribute('hasactiveplan');
- }
- if (data.activated) {
+
+ if (data.activated)
page.setAttribute('activated', true);
- } else {
+ else
page.removeAttribute('activated');
- }
+ if (data.showBuyButton)
+ page.setAttribute('showbuy', true);
+ else
+ page.removeAttribute('showbuy');
+
+ if (data.showActivateButton)
+ page.setAttribute('showactivate', true);
+ else
+ page.removeAttribute('showactivate');
+
// Nudge webkit so that it redraws the details overlay page.
// See http://crosbug.com/9616 for details.
// Webkit bug: https://bugs.webkit.org/show_bug.cgi?id=50176
@@ -339,6 +349,16 @@
$('imsi').textContent = data.imsi;
page.setAttribute('gsm', true);
}
+
+ if (data.showBuyButton)
+ page.setAttribute('showbuy', true);
+ else
+ page.removeAttribute('showbuy');
+ if (data.showActivateButton)
+ page.setAttribute('showactivate', true);
+ else
+ page.removeAttribute('showactivate');
+
page.removeAttribute('hascellplan');
if (data.connected) {
page.removeAttribute('nocellplan');

Powered by Google App Engine
This is Rietveld 408576698