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 6083af00dab721f0be646524f37501d0e7fdf0bd..ddfa1a6bdcf83c0bb0769aaaa4807dcc534dabfc 100644 |
--- a/chrome/browser/resources/extensions/extension_list.js |
+++ b/chrome/browser/resources/extensions/extension_list.js |
@@ -65,7 +65,7 @@ |
*/ |
var ExtensionData; |
-cr.define('options', function() { |
+cr.define('extensions', function() { |
'use strict'; |
/** |
@@ -74,7 +74,7 @@ cr.define('options', function() { |
* @constructor |
* @extends {HTMLDivElement} |
*/ |
- var ExtensionsList = cr.ui.define('div'); |
+ var ExtensionList = cr.ui.define('div'); |
/** |
* @type {Object<string, number>} A map from extension id to last reloaded |
@@ -84,7 +84,7 @@ cr.define('options', function() { |
*/ |
var extensionReloadedTimestamp = {}; |
- ExtensionsList.prototype = { |
+ ExtensionList.prototype = { |
__proto__: HTMLDivElement.prototype, |
/** |
@@ -286,6 +286,8 @@ cr.define('options', function() { |
var trash = trashTemplate.cloneNode(true); |
trash.title = loadTimeData.getString('extensionUninstall'); |
trash.addEventListener('click', function(e) { |
+ trash.classList.add('open'); |
+ trash.classList.toggle('mouse-clicked', e.detail > 0); |
chrome.send('extensionSettingsUninstall', [extension.id]); |
}); |
node.querySelector('.enable-controls').appendChild(trash); |
@@ -701,7 +703,14 @@ cr.define('options', function() { |
}, |
}; |
+ ExtensionList.uninstallCancel = function() { |
+ var trash = document.querySelector('.trash.open'); |
+ if (trash.classList.contains('mouse-clicked')) |
Evan Stade
2015/02/26 02:49:19
seems like this can crash if .trash.open is not fo
Dan Beam
2015/02/26 03:02:42
i think that'd be unexpected and therefore should
|
+ trash.blur(); |
+ trash.classList.remove('open'); |
+ }; |
+ |
return { |
- ExtensionsList: ExtensionsList |
+ ExtensionList: ExtensionList |
}; |
}); |