| 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 /** | 5 /** |
| 6 * @fileoverview 'settings-detailed-build-info' contains detailed build | 6 * @fileoverview 'settings-detailed-build-info' contains detailed build |
| 7 * information for ChromeOS. | 7 * information for ChromeOS. |
| 8 */ | 8 */ |
| 9 | 9 |
| 10 Polymer({ | 10 Polymer({ |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 48 | 48 |
| 49 /** | 49 /** |
| 50 * @param {string} version | 50 * @param {string} version |
| 51 * @return {boolean} | 51 * @return {boolean} |
| 52 * @private | 52 * @private |
| 53 */ | 53 */ |
| 54 shouldShowVersion_: function(version) { | 54 shouldShowVersion_: function(version) { |
| 55 return version.length > 0; | 55 return version.length > 0; |
| 56 }, | 56 }, |
| 57 | 57 |
| 58 /** @private */ | 58 /** |
| 59 onChangeChannelTap_: function() { | 59 * @param {!Event} e |
| 60 * @private |
| 61 */ |
| 62 onChangeChannelTap_: function(e) { |
| 63 e.preventDefault(); |
| 60 this.showChannelSwitcherDialog_ = true; | 64 this.showChannelSwitcherDialog_ = true; |
| 61 // Async to wait for dialog to appear in the DOM. | 65 // Async to wait for dialog to appear in the DOM. |
| 62 this.async(function() { | 66 this.async(function() { |
| 63 var dialog = this.$$('settings-channel-switcher-dialog'); | 67 var dialog = this.$$('settings-channel-switcher-dialog'); |
| 64 // Register listener to detect when the dialog is closed. Flip the boolean | 68 // Register listener to detect when the dialog is closed. Flip the boolean |
| 65 // once closed to force a restamp next time it is shown such that the | 69 // once closed to force a restamp next time it is shown such that the |
| 66 // previous dialog's contents are cleared. | 70 // previous dialog's contents are cleared. |
| 67 dialog.addEventListener('close', function() { | 71 dialog.addEventListener('close', function() { |
| 68 this.showChannelSwitcherDialog_ = false; | 72 this.showChannelSwitcherDialog_ = false; |
| 69 }.bind(this)); | 73 }.bind(this)); |
| 70 }.bind(this)); | 74 }.bind(this)); |
| 71 }, | 75 }, |
| 72 }); | 76 }); |
| OLD | NEW |