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

Side by Side Diff: lib/src/iron-selector/iron-multi-selectable.html

Issue 1418513006: update elements and fix some bugs (Closed) Base URL: git@github.com:dart-lang/polymer_elements.git@master
Patch Set: code review updates Created 5 years, 1 month 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
« no previous file with comments | « lib/src/iron-range-behavior/test/basic.html ('k') | lib/src/iron-selector/iron-selectable.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!-- 1 <!--
2 @license 2 @license
3 Copyright (c) 2015 The Polymer Project Authors. All rights reserved. 3 Copyright (c) 2015 The Polymer Project Authors. All rights reserved.
4 This code may only be used under the BSD style license found at http://polymer.g ithub.io/LICENSE.txt 4 This code may only be used under the BSD style license found at http://polymer.g ithub.io/LICENSE.txt
5 The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt 5 The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
6 The complete set of contributors may be found at http://polymer.github.io/CONTRI BUTORS.txt 6 The complete set of contributors may be found at http://polymer.github.io/CONTRI BUTORS.txt
7 Code distributed by Google as part of the polymer project is also 7 Code distributed by Google as part of the polymer project is also
8 subject to an additional IP rights grant found at http://polymer.github.io/PATEN TS.txt 8 subject to an additional IP rights grant found at http://polymer.github.io/PATEN TS.txt
9 --> 9 -->
10 10
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 } else { 96 } else {
97 this._setSelectedItems([s]); 97 this._setSelectedItems([s]);
98 this._setSelectedItem(s); 98 this._setSelectedItem(s);
99 } 99 }
100 }, 100 },
101 101
102 _toggleSelected: function(value) { 102 _toggleSelected: function(value) {
103 var i = this.selectedValues.indexOf(value); 103 var i = this.selectedValues.indexOf(value);
104 var unselected = i < 0; 104 var unselected = i < 0;
105 if (unselected) { 105 if (unselected) {
106 this.selectedValues.push(value); 106 this.push('selectedValues',value);
107 } else { 107 } else {
108 this.selectedValues.splice(i, 1); 108 this.splice('selectedValues',i,1);
109 } 109 }
110 this._selection.setItemSelected(this._valueToItem(value), unselected); 110 this._selection.setItemSelected(this._valueToItem(value), unselected);
111 } 111 }
112 }; 112 };
113 113
114 /** @polymerBehavior */ 114 /** @polymerBehavior */
115 Polymer.IronMultiSelectableBehavior = [ 115 Polymer.IronMultiSelectableBehavior = [
116 Polymer.IronSelectableBehavior, 116 Polymer.IronSelectableBehavior,
117 Polymer.IronMultiSelectableBehaviorImpl 117 Polymer.IronMultiSelectableBehaviorImpl
118 ]; 118 ];
119 119
120 </script> 120 </script>
OLDNEW
« no previous file with comments | « lib/src/iron-range-behavior/test/basic.html ('k') | lib/src/iron-selector/iron-selectable.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698