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

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

Issue 8176001: Warn user in case extension delays network traffic too much. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Cleanup Created 9 years, 2 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/extension_list.js
diff --git a/chrome/browser/resources/options/extension_list.js b/chrome/browser/resources/options/extension_list.js
index 0e852eb862b2c06a5729fa202037f5f4f84e2a50..deb7b06ae2303c8a8d041cf587897f54bd31d8d3 100644
--- a/chrome/browser/resources/options/extension_list.js
+++ b/chrome/browser/resources/options/extension_list.js
@@ -239,6 +239,27 @@ cr.define('options', function() {
vbox.appendChild(link);
}
+ if (extension.warnings.length > 0) {
Finnur 2011/10/10 10:02:39 I guess this is a question for Glen... Was the int
battre 2011/10/10 13:16:36 This was my intent: Always show it if and only if
+ var warningsDiv = this.ownerDocument.createElement('div');
+ warningsDiv.classList.add('extension-warnings');
Finnur 2011/10/10 09:59:24 nit: You use plural here (warnings) but singular f
battre 2011/10/10 13:16:36 Given the confusion from the comment below, I have
+
+ var warningHeader = this.ownerDocument.createElement('span');
+ warningHeader.classList.add('extension-warning-title');
+ warningHeader.textContent =
+ localStrings.getString('extensionSettingsWarningsTitle');
+ warningsDiv.appendChild(warningHeader);
+
+ var warningList = this.ownerDocument.createElement('ul');
+ for (var j = 0; j < extension.warnings.length; ++j) {
+ var warningEntry = this.ownerDocument.createElement('li');
+ warningEntry.textContent = extension.warnings[j];
+ warningList.appendChild(warningEntry);
Finnur 2011/10/10 09:59:24 For non-network-slowdown warnings this will look w
battre 2011/10/10 13:16:36 I am not sure I understand this. This is the reaso
Finnur 2011/10/10 15:06:56 Ignore this comment, addressed elsewhere. On 2011
+ }
+ warningsDiv.appendChild(warningList);
+
+ vbox.appendChild(warningsDiv);
+ }
+
// And now the details section that is normally hidden.
var details = this.ownerDocument.createElement('div');
details.classList.add('vbox');
@@ -711,4 +732,4 @@ cr.define('options', function() {
return {
ExtensionsList: ExtensionsList
};
-});
+});

Powered by Google App Engine
This is Rietveld 408576698