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

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

Issue 2210933004: Settings Router Refactor: Kill settings-router. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: merge yet again because this conflicts with everything 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 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-on-startup-page' is a settings page. 7 * 'settings-on-startup-page' is a settings page.
8 * 8 *
9 * Example: 9 * Example:
10 * 10 *
11 * <neon-animated-pages> 11 * <neon-animated-pages>
12 * <settings-on-startup-page prefs="{{prefs}}"> 12 * <settings-on-startup-page prefs="{{prefs}}">
13 * </settings-on-startup-page> 13 * </settings-on-startup-page>
14 * ... other pages ... 14 * ... other pages ...
15 * </neon-animated-pages> 15 * </neon-animated-pages>
16 */ 16 */
17 Polymer({ 17 Polymer({
18 is: 'settings-on-startup-page', 18 is: 'settings-on-startup-page',
19 19
20 properties: { 20 properties: {
21 /** 21 /**
22 * Preferences state. 22 * Preferences state.
23 */ 23 */
24 prefs: { 24 prefs: {
25 type: Object, 25 type: Object,
26 notify: true, 26 notify: true,
27 }, 27 },
28 28
29 /** 29 /**
30 * The current active route.
31 */
32 currentRoute: {
33 type: Object,
34 notify: true,
35 },
36
37 /**
38 * Enum values for the 'session.restore_on_startup' preference. 30 * Enum values for the 'session.restore_on_startup' preference.
39 * @private {!Object<string, number>} 31 * @private {!Object<string, number>}
40 */ 32 */
41 prefValues_: { 33 prefValues_: {
42 readOnly: true, 34 readOnly: true,
43 type: Object, 35 type: Object,
44 value: { 36 value: {
45 OPEN_NEW_TAB: 5, 37 OPEN_NEW_TAB: 5,
46 CONTINUE: 1, 38 CONTINUE: 1,
47 OPEN_SPECIFIC: 4, 39 OPEN_SPECIFIC: 4,
48 }, 40 },
49 }, 41 },
50 }, 42 },
51 43
52 /** 44 /**
53 * Determine whether to show the user defined startup pages. 45 * Determine whether to show the user defined startup pages.
54 * @param {number} restoreOnStartup Enum value from prefValues_. 46 * @param {number} restoreOnStartup Enum value from prefValues_.
55 * @return {boolean} Whether the open specific pages is selected. 47 * @return {boolean} Whether the open specific pages is selected.
56 * @private 48 * @private
57 */ 49 */
58 showStartupUrls_: function(restoreOnStartup) { 50 showStartupUrls_: function(restoreOnStartup) {
59 return restoreOnStartup == this.prefValues_.OPEN_SPECIFIC; 51 return restoreOnStartup == this.prefValues_.OPEN_SPECIFIC;
60 }, 52 },
61 }); 53 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698