Chromium Code Reviews| Index: chrome/browser/resources/extensions/extension_list.js |
| diff --git a/chrome/browser/resources/extensions/extension_list.js b/chrome/browser/resources/extensions/extension_list.js |
| index 59f5d008ba360771bc977d9a6cba875249f1822b..909f8e771816a735f103d5f41918df94eeda4614 100644 |
| --- a/chrome/browser/resources/extensions/extension_list.js |
| +++ b/chrome/browser/resources/extensions/extension_list.js |
| @@ -2,22 +2,12 @@ |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| +<include src="extension_error.js"></include> |
| + |
| cr.define('options', function() { |
| 'use strict'; |
| /** |
| - * A lookup helper function to find the first node that has an id (starting |
| - * at |node| and going up the parent chain). |
| - * @param {Element} node The node to start looking at. |
| - */ |
| - function findIdNode(node) { |
| - while (node && !node.id) { |
| - node = node.parentNode; |
| - } |
| - return node; |
| - } |
| - |
| - /** |
| * Creates a new list of extensions. |
| * @param {Object=} opt_propertyBag Optional properties. |
| * @constructor |
| @@ -322,16 +312,11 @@ cr.define('options', function() { |
| }); |
| } |
| - // The install warnings. |
| - if (extension.installWarnings) { |
| - var panel = node.querySelector('.install-warnings'); |
| - panel.hidden = false; |
| - var list = panel.querySelector('ul'); |
| - extension.installWarnings.forEach(function(warning) { |
| - var li = document.createElement('li'); |
| - li.innerText = warning.message; |
| - list.appendChild(li); |
| - }); |
| + // The manifest errors and warnings. |
| + if (extension.manifestErrors) { |
| + node.querySelector('.manifest-errors').hidden = false; |
|
Dan Beam
2013/08/20 21:39:26
nit: only query selector once, IMO
var errors = n
Devlin
2013/08/20 23:06:51
Done.
|
| + node.querySelector('.manifest-errors').appendChild( |
| + new extensions.ExtensionErrorList(extension.manifestErrors)); |
| } |
| this.appendChild(node); |
| @@ -344,7 +329,7 @@ cr.define('options', function() { |
| topScroll -= pad / 2; |
| document.body.scrollTop = topScroll; |
| } |
| - } |
| + }, |
| }; |
| return { |