| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 Polymer({ | 5 Polymer({ |
| 6 is: 'bookmarks-toolbar', | 6 is: 'bookmarks-toolbar', |
| 7 | 7 |
| 8 properties: { | 8 properties: { |
| 9 searchTerm: { | 9 searchTerm: { |
| 10 type: String, | 10 type: String, |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 62 * @param {Event} e | 62 * @param {Event} e |
| 63 * @private | 63 * @private |
| 64 */ | 64 */ |
| 65 onSearchChanged_: function(e) { | 65 onSearchChanged_: function(e) { |
| 66 var searchTerm = /** @type {string} */ (e.detail); | 66 var searchTerm = /** @type {string} */ (e.detail); |
| 67 this.fire('search-term-changed', searchTerm); | 67 this.fire('search-term-changed', searchTerm); |
| 68 }, | 68 }, |
| 69 | 69 |
| 70 /** @private */ | 70 /** @private */ |
| 71 onSearchTermChanged_: function() { | 71 onSearchTermChanged_: function() { |
| 72 if (!this.searchTerm) | 72 this.searchField.setValue(this.searchTerm || ''); |
| 73 this.searchField.setValue(''); | |
| 74 }, | 73 }, |
| 75 }); | 74 }); |
| OLD | NEW |