OLD | NEW |
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. |
4 | 4 |
5 cr.define('options.contentSettings', function() { | 5 cr.define('options.contentSettings', function() { |
6 /** @const */ var ControlledSettingIndicator = | 6 /** @const */ var ControlledSettingIndicator = |
7 options.ControlledSettingIndicator; | 7 options.ControlledSettingIndicator; |
8 /** @const */ var InlineEditableItemList = options.InlineEditableItemList; | 8 /** @const */ var InlineEditableItemList = options.InlineEditableItemList; |
9 /** @const */ var InlineEditableItem = options.InlineEditableItem; | 9 /** @const */ var InlineEditableItem = options.InlineEditableItem; |
10 /** @const */ var ArrayDataModel = cr.ui.ArrayDataModel; | 10 /** @const */ var ArrayDataModel = cr.ui.ArrayDataModel; |
(...skipping 561 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
572 } | 572 } |
573 }, | 573 }, |
574 | 574 |
575 /** @override */ | 575 /** @override */ |
576 deleteItemAtIndex: function(index) { | 576 deleteItemAtIndex: function(index) { |
577 var listItem = this.getListItemByIndex(index); | 577 var listItem = this.getListItemByIndex(index); |
578 if (!listItem.deletable) | 578 if (!listItem.deletable) |
579 return; | 579 return; |
580 | 580 |
581 var dataItem = listItem.dataItem; | 581 var dataItem = listItem.dataItem; |
582 var args = [listItem.contentType]; | 582 chrome.send('removeException', [listItem.contentType, |
583 if (listItem.contentType == 'notifications') | 583 listItem.mode, |
584 args.push(dataItem.origin, dataItem.setting); | 584 dataItem.origin, |
585 else | 585 dataItem.embeddingOrigin]); |
586 args.push(listItem.mode, dataItem.origin, dataItem.embeddingOrigin); | |
587 | |
588 chrome.send('removeException', args); | |
589 }, | 586 }, |
590 }; | 587 }; |
591 | 588 |
592 var Page = cr.ui.pageManager.Page; | 589 var Page = cr.ui.pageManager.Page; |
593 var PageManager = cr.ui.pageManager.PageManager; | 590 var PageManager = cr.ui.pageManager.PageManager; |
594 | 591 |
595 /** | 592 /** |
596 * Encapsulated handling of content settings list subpage. | 593 * Encapsulated handling of content settings list subpage. |
597 * | 594 * |
598 * @constructor | 595 * @constructor |
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
685 } | 682 } |
686 }; | 683 }; |
687 | 684 |
688 return { | 685 return { |
689 ExceptionsListItem: ExceptionsListItem, | 686 ExceptionsListItem: ExceptionsListItem, |
690 ExceptionsAddRowListItem: ExceptionsAddRowListItem, | 687 ExceptionsAddRowListItem: ExceptionsAddRowListItem, |
691 ExceptionsList: ExceptionsList, | 688 ExceptionsList: ExceptionsList, |
692 ContentSettingsExceptionsArea: ContentSettingsExceptionsArea, | 689 ContentSettingsExceptionsArea: ContentSettingsExceptionsArea, |
693 }; | 690 }; |
694 }); | 691 }); |
OLD | NEW |