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

Side by Side Diff: chrome/browser/resources/apps_debugger/js/items_list.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: Addressed comments 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file..
Dan Beam 2013/02/11 23:44:24 remove second .
Gaurav 2013/02/12 19:33:17 Done.
4 4
5 cr.define('apps_dev_tool', function() { 5 cr.define('apps_dev_tool', function() {
6 'use strict'; 6 'use strict';
7 7
8 /* Creates a new list of items. 8 /* Creates a new list of items.
9 * @param {Object=} opt_propertyBag Optional properties. 9 * @param {Object=} opt_propertyBag Optional properties.
10 * @constructor 10 * @constructor
11 */ 11 */
12 var ItemsList = cr.ui.define('div'); 12 var ItemsList = cr.ui.define('div');
13 13
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after
192 * @private 192 * @private
193 */ 193 */
194 setEnabledCheckbox_: function(item, el) { 194 setEnabledCheckbox_: function(item, el) {
195 var enable = el.querySelector('.enable-checkbox'); 195 var enable = el.querySelector('.enable-checkbox');
196 enable.hidden = false; 196 enable.hidden = false;
197 enable.querySelector('input').disabled = !item.may_disable; 197 enable.querySelector('input').disabled = !item.may_disable;
198 198
199 if (item.may_disable) { 199 if (item.may_disable) {
200 enable.addEventListener('click', function(e) { 200 enable.addEventListener('click', function(e) {
201 chrome.developerPrivate.enable( 201 chrome.developerPrivate.enable(
202 item.id, e.target.checked, loadItemsInfo); 202 item.id, !!e.target.checked, loadItemsInfo);
203 }); 203 });
204 } 204 }
205 205
206 enable.querySelector('input').checked = item.enabled; 206 enable.querySelector('input').checked = item.enabled;
207 }, 207 },
208 208
209 209
210 /** 210 /**
211 * Sets the handler for the allow_file_access checkbox. 211 * Sets the handler for the allow_file_access checkbox.
212 * @param {!object} item A dictionary of item metadata. 212 * @param {!object} item A dictionary of item metadata.
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
261 } 261 }
262 }); 262 });
263 } 263 }
264 } 264 }
265 }; 265 };
266 266
267 return { 267 return {
268 ItemsList: ItemsList, 268 ItemsList: ItemsList,
269 }; 269 };
270 }); 270 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698