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

Unified Diff: chrome/browser/resources/apps_debugger/js/items.js

Issue 11794034: Adds functionality to pack an extension / app from the app. (Closed) Base URL: http://git.chromium.org/chromium/src.git@bacha_lo
Patch Set: . Created 7 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/apps_debugger/js/items.js
diff --git a/chrome/browser/resources/apps_debugger/js/items.js b/chrome/browser/resources/apps_debugger/js/items.js
index 27f658de5c2ec4e62e2afbee08515320c23b5f39..e3bc223571fd0e29154e5c0c294ed936b181dd6f 100644
--- a/chrome/browser/resources/apps_debugger/js/items.js
+++ b/chrome/browser/resources/apps_debugger/js/items.js
@@ -22,8 +22,12 @@ cr.define('apps_dev_tool', function() {
// Set up the three buttons (load unpacked, pack and update).
$('load-unpacked').addEventListener('click',
this.handleLoadUnpackedItem_.bind(this));
+ $('pack-item').addEventListener('click',
+ this.handlePackItem_.bind(this));
$('update-items-now').addEventListener('click',
this.handleUpdateItemNow_.bind(this));
+ var packItemOverlay =
+ apps_dev_tool.PackItemOverlay.getInstance().initializePage();
},
/**
@@ -37,6 +41,14 @@ cr.define('apps_dev_tool', function() {
});
},
+ /** Handles the Pack Extension button.
+ * @param {Event} e Change event.
+ * @private
+ */
+ handlePackItem_: function(e) {
+ AppsDevTool.showOverlay($('packItemOverlay'));
+ },
+
/**
* Handles the Update Extension Now Button.
* @param {!Event} e Click event.
@@ -64,10 +76,8 @@ cr.define('apps_dev_tool', function() {
var currentlyShowingOverlay = AppsDevTool.getCurrentOverlay();
if (currentlyShowingOverlay)
currentlyShowingOverlay.classList.remove('showing');
-
if (el)
el.classList.add('showing');
-
overlay.hidden = !el;
uber.invokeMethodOnParent(el ? 'beginInterceptingEvents' :
'stopInterceptingEvents');

Powered by Google App Engine
This is Rietveld 408576698