| Index: third_party/polymer/v1_0/components-chromium/iron-selector/iron-multi-selectable-extracted.js
|
| diff --git a/third_party/polymer/v1_0/components-chromium/iron-selector/iron-multi-selectable-extracted.js b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-multi-selectable-extracted.js
|
| index 38b18a869f2887733b152d4bf346e0366b67cf21..66da86debbeaf8703d14d0a3f0eaa12848b1e631 100644
|
| --- a/third_party/polymer/v1_0/components-chromium/iron-selector/iron-multi-selectable-extracted.js
|
| +++ b/third_party/polymer/v1_0/components-chromium/iron-selector/iron-multi-selectable-extracted.js
|
| @@ -32,7 +32,7 @@
|
| },
|
|
|
| observers: [
|
| - '_updateSelected(selectedValues)'
|
| + '_updateSelected(selectedValues.splices)'
|
| ],
|
|
|
| /**
|
| @@ -68,7 +68,7 @@
|
| Polymer.IronSelectableBehavior._updateAttrForSelected.apply(this);
|
| } else if (this._shouldUpdateSelection) {
|
| this.selectedValues = this.selectedItems.map(function(selectedItem) {
|
| - return this._indexToValue(this.indexOf(selectedItem));
|
| + return this._indexToValue(this.indexOf(selectedItem));
|
| }, this).filter(function(unfilteredValue) {
|
| return unfilteredValue != null;
|
| }, this);
|
| @@ -92,6 +92,13 @@
|
| for (var i = 0; i < selectedItems.length; i++) {
|
| this._selection.setItemSelected(selectedItems[i], true);
|
| }
|
| + // Check for items, since this array is populated only when attached
|
| + if (this.fallbackSelection && this.items.length && !this._selection.get().length) {
|
| + var fallback = this._valueToItem(this.fallbackSelection);
|
| + if (fallback) {
|
| + this.selectedValues = [this.fallbackSelection];
|
| + }
|
| + }
|
| } else {
|
| this._selection.clear();
|
| }
|
| @@ -115,7 +122,6 @@
|
| } else {
|
| this.splice('selectedValues',i,1);
|
| }
|
| - this._selection.setItemSelected(this._valueToItem(value), unselected);
|
| },
|
|
|
| _valuesToItems: function(values) {
|
|
|