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

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

Issue 462273003: Show extension name for dependent extensions (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: use template Created 6 years, 4 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/extensions/extension_list.js
diff --git a/chrome/browser/resources/extensions/extension_list.js b/chrome/browser/resources/extensions/extension_list.js
index 7067da5d00362dd398a95e914e17ca357a3a74ea..973ec581ecbc2c9c7f5ec1e56b183ec3ea7347ea 100644
--- a/chrome/browser/resources/extensions/extension_list.js
+++ b/chrome/browser/resources/extensions/extension_list.js
@@ -321,10 +321,15 @@ cr.define('options', function() {
node.querySelector('.dependent-extensions-message');
dependentMessage.hidden = false;
var dependentList = dependentMessage.querySelector('ul');
- extension.dependentExtensions.forEach(function(id) {
- var li = document.createElement('li');
- li.innerText = id;
- dependentList.appendChild(li);
+ extension.dependentExtensions.forEach(function(elem) {
+ var dependentTemplate = $('template-dependent').querySelector(
+ '.dependent-list-item');
not at google - send to devlin 2014/08/13 19:43:47 Save this outside the forEach loop?
elijahtaylor1 2014/08/13 21:12:45 Done.
+ var dependentNode = dependentTemplate.cloneNode(true);
+ var dependentTitle = dependentNode.querySelector('.extension-title');
+ dependentTitle.textContent = elem.name;
not at google - send to devlin 2014/08/13 19:43:47 Nit: to save on the saturation of "dependent*" var
elijahtaylor1 2014/08/13 21:12:45 Done.
+ var dependentId = dependentNode.querySelector('.extension-id');
+ dependentId.textContent = elem.id;
+ dependentList.appendChild(dependentNode);
});
}

Powered by Google App Engine
This is Rietveld 408576698