| OLD | NEW |
| (Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 /** |
| 6 * @fileoverview Polymer element for displaying material design Terms Of Service |
| 7 * screen. |
| 8 */ |
| 9 |
| 10 Polymer({ |
| 11 is: 'oobe-eula-md', |
| 12 |
| 13 properties: { |
| 14 /** |
| 15 * Shows "Loading..." section. |
| 16 */ |
| 17 eulaLoadingScreenShown: { |
| 18 type: Boolean, |
| 19 value: false, |
| 20 }, |
| 21 |
| 22 /** |
| 23 * Shows Terms Of Service frame. |
| 24 */ |
| 25 eulaScreenShown: { |
| 26 type: Array, |
| 27 }, |
| 28 |
| 29 /** |
| 30 * "Accepot and continue" button is disabled until content is loaded. |
| 31 */ |
| 32 acceptButtonDisabled: { |
| 33 type: Boolean, |
| 34 value: true, |
| 35 }, |
| 36 }, |
| 37 |
| 38 /** |
| 39 * Event handler that is invoked when 'chrome://terms' is loaded. |
| 40 */ |
| 41 onFrameLoad_: function() { |
| 42 this.acceptButtonDisabled = false; |
| 43 }, |
| 44 |
| 45 /** |
| 46 * This is called when strings are updated. |
| 47 */ |
| 48 updateLocalizedContent: function(event) { |
| 49 // This forces frame to reload. |
| 50 this.$.crosEulaFrame.src = this.$.crosEulaFrame.src; |
| 51 }, |
| 52 |
| 53 /** |
| 54 * This is 'on-tap' event handler for 'Accept' button. |
| 55 */ |
| 56 eulaAccepted_: function(event) { |
| 57 chrome.send('login.EulaScreen.userActed', ['accept-button']); |
| 58 }, |
| 59 }); |
| OLD | NEW |