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

Side by Side Diff: chrome/browser/resources/chromeos/login/oobe_eula.js

Issue 2269433002: ChromeOS: Add more controls to OOBE EULA screen. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update. Created 4 years, 4 months 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
OLDNEW
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 Polymer element for displaying material design Terms Of Service 6 * @fileoverview Polymer element for displaying material design Terms Of Service
7 * screen. 7 * screen.
8 */ 8 */
9 9
10 Polymer({ 10 Polymer({
(...skipping 15 matching lines...) Expand all
26 type: Array, 26 type: Array,
27 }, 27 },
28 28
29 /** 29 /**
30 * "Accepot and continue" button is disabled until content is loaded. 30 * "Accepot and continue" button is disabled until content is loaded.
31 */ 31 */
32 acceptButtonDisabled: { 32 acceptButtonDisabled: {
33 type: Boolean, 33 type: Boolean,
34 value: true, 34 value: true,
35 }, 35 },
36
37 /**
38 * If "Report anonymous usage stats" checkbox is checked.
39 */
40 usageStatsChecked: {
41 type: Boolean,
42 value: false,
43 },
44
45 /*
stevenjb 2016/08/23 16:45:17 /**
Alexander Alekseev 2016/08/25 01:28:22 Done.
46 * Reference to OOBE screen object.
47 */
48 screen: {
49 type: Object,
stevenjb 2016/08/23 16:45:17 Please typedef this.
Alexander Alekseev 2016/08/25 01:28:22 Done.
50 },
36 }, 51 },
37 52
38 /** 53 /**
39 * Event handler that is invoked when 'chrome://terms' is loaded. 54 * Event handler that is invoked when 'chrome://terms' is loaded.
40 */ 55 */
41 onFrameLoad_: function() { 56 onFrameLoad_: function() {
42 this.acceptButtonDisabled = false; 57 this.acceptButtonDisabled = false;
43 }, 58 },
44 59
45 /** 60 /**
46 * This is called when strings are updated. 61 * This is called when strings are updated.
47 */ 62 */
48 updateLocalizedContent: function(event) { 63 updateLocalizedContent: function(event) {
49 // This forces frame to reload. 64 // This forces frame to reload.
50 this.$.crosEulaFrame.src = this.$.crosEulaFrame.src; 65 this.$.crosEulaFrame.src = this.$.crosEulaFrame.src;
51 }, 66 },
52 67
53 /** 68 /**
54 * This is 'on-tap' event handler for 'Accept' button. 69 * This is 'on-tap' event handler for 'Accept' button.
55 */ 70 */
56 eulaAccepted_: function(event) { 71 eulaAccepted_: function(event) {
57 chrome.send('login.EulaScreen.userActed', ['accept-button']); 72 chrome.send('login.EulaScreen.userActed', ['accept-button']);
58 }, 73 },
74
75 /**
76 * On-change event handler for usageStats.
77 *
78 * * @private
79 */
80 onUsageChanged_: function() {
81 this.screen.onUsageStatsClicked_(this.$.usageStats.checked);
82 },
83
84 /**
85 * On-tap event handler for installationSettings.
86 *
87 * * @private
88 */
89 onInstallationSettingsClicked_: function() {
90 chrome.send('eulaOnInstallationSettingsPopupOpened');
91 $('popup-overlay').hidden = false;
92 $('installation-settings-ok-button').focus();
93 },
94
95 /**
96 * On-tap event handler for stats-help-link.
97 *
98 * * @private
99 */
100 onUsageStatsHelpLinkClicked_: function() {
101 chrome.send('eulaOnLearnMore');
102 },
59 }); 103 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698