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

Side by Side Diff: chrome/browser/resources/options/content_settings_exceptions_area.js

Issue 6155008: DOMUI: Implement the new Fonts and Encoding page. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Review fix 3. Created 9 years, 11 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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.
4 4
5 cr.define('options.contentSettings', function() { 5 cr.define('options.contentSettings', function() {
6 const DeletableItemList = options.DeletableItemList; 6 const DeletableItemList = options.DeletableItemList;
7 const DeletableItem = options.DeletableItem; 7 const DeletableItem = options.DeletableItem;
8 const ArrayDataModel = cr.ui.ArrayDataModel; 8 const ArrayDataModel = cr.ui.ArrayDataModel;
9 9
10 /** 10 /**
11 * Creates a new exceptions list item. 11 * Creates a new exceptions list item.
(...skipping 494 matching lines...) Expand 10 before | Expand all | Expand 10 after
506 // The null creates the Add New Exception row. 506 // The null creates the Add New Exception row.
507 this.dataModel = new ArrayDataModel([null]); 507 this.dataModel = new ArrayDataModel([null]);
508 } else { 508 } else {
509 this.dataModel = new ArrayDataModel([]); 509 this.dataModel = new ArrayDataModel([]);
510 } 510 }
511 }, 511 },
512 512
513 /** @inheritDoc */ 513 /** @inheritDoc */
514 deleteItemAtIndex: function(index) { 514 deleteItemAtIndex: function(index) {
515 var listItem = this.getListItemByIndex(index); 515 var listItem = this.getListItemByIndex(index);
516 if (listItem.undeletable) { 516 if (listItem.undeletable)
517 console.log('Tried to delete an undeletable row.');
518 return; 517 return;
519 }
520 518
521 var dataItem = listItem.dataItem; 519 var dataItem = listItem.dataItem;
522 var args = [listItem.contentType]; 520 var args = [listItem.contentType];
523 if (listItem.contentType == 'location') 521 if (listItem.contentType == 'location')
524 args.push(dataItem['origin'], dataItem['embeddingOrigin']); 522 args.push(dataItem['origin'], dataItem['embeddingOrigin']);
525 else if (listItem.contentType == 'notifications') 523 else if (listItem.contentType == 'notifications')
526 args.push(dataItem['origin'], dataItem['setting']); 524 args.push(dataItem['origin'], dataItem['setting']);
527 else 525 else
528 args.push(listItem.mode, listItem.pattern); 526 args.push(listItem.mode, listItem.pattern);
529 527
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
604 } 602 }
605 }; 603 };
606 604
607 return { 605 return {
608 ExceptionsListItem: ExceptionsListItem, 606 ExceptionsListItem: ExceptionsListItem,
609 ExceptionsAddRowListItem: ExceptionsAddRowListItem, 607 ExceptionsAddRowListItem: ExceptionsAddRowListItem,
610 ExceptionsList: ExceptionsList, 608 ExceptionsList: ExceptionsList,
611 ContentSettingsExceptionsArea: ContentSettingsExceptionsArea, 609 ContentSettingsExceptionsArea: ContentSettingsExceptionsArea,
612 }; 610 };
613 }); 611 });
OLDNEW
« no previous file with comments | « chrome/browser/resources/options/chromeos_proxy_rules_list.js ('k') | chrome/browser/resources/options/font_settings.css » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698