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

Side by Side Diff: chrome/browser/resources/settings/basic_page/basic_page.js

Issue 2861443003: MD Settings: Fix subpage visibility and add appearance page tests (Closed)
Patch Set: Remove cleanup Created 3 years, 7 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 6 * @fileoverview
7 * 'settings-basic-page' is the settings page containing the actual settings. 7 * 'settings-basic-page' is the settings page containing the actual settings.
8 */ 8 */
9 Polymer({ 9 Polymer({
10 is: 'settings-basic-page', 10 is: 'settings-basic-page',
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
135 /** 135 /**
136 * @param {boolean|undefined} visibility 136 * @param {boolean|undefined} visibility
137 * @return {boolean} 137 * @return {boolean}
138 * @private 138 * @private
139 */ 139 */
140 showPage_: function(visibility) { 140 showPage_: function(visibility) {
141 return visibility !== false; 141 return visibility !== false;
142 }, 142 },
143 143
144 /** 144 /**
145 * @param {!PageVisibility} visibility
145 * @param {string} subpage 146 * @param {string} subpage
146 * @return {!Object} 147 * @return {!Object}
147 */ 148 */
148 getPageVisibility_: function(subpage) { 149 getPageVisibility_: function(visibility, subpage) {
149 return /** @type {Object} */ (this.get(subpage, this.pageVisibility)) || {}; 150 return /** @type {Object} */ (this.get(subpage, visibility)) || {};
dpapad 2017/05/04 01:03:24 I tried the CL locally and I still see the section
150 }, 151 },
151 152
152 // <if expr="chromeos"> 153 // <if expr="chromeos">
153 /** 154 /**
154 * @return {boolean} 155 * @return {boolean}
155 * @private 156 * @private
156 */ 157 */
157 computeShowSecondaryUserBanner_: function() { 158 computeShowSecondaryUserBanner_: function() {
158 return !this.hasExpandedSection_ && 159 return !this.hasExpandedSection_ &&
159 loadTimeData.getBoolean('isSecondaryUser'); 160 loadTimeData.getBoolean('isSecondaryUser');
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
225 226
226 /** 227 /**
227 * @param {boolean} opened Whether the menu is expanded. 228 * @param {boolean} opened Whether the menu is expanded.
228 * @return {string} Icon name. 229 * @return {string} Icon name.
229 * @private 230 * @private
230 */ 231 */
231 getArrowIcon_: function(opened) { 232 getArrowIcon_: function(opened) {
232 return opened ? 'cr:arrow-drop-up' : 'cr:arrow-drop-down'; 233 return opened ? 'cr:arrow-drop-up' : 'cr:arrow-drop-down';
233 }, 234 },
234 }); 235 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698