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

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

Issue 2231203002: Settings Router Refactor: Normalize URL only for main settings page. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address comments 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
« no previous file with comments | « chrome/browser/resources/settings/settings.html ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 cr.exportPath('settings'); 5 cr.exportPath('settings');
6 assert(!settings.defaultResourceLoaded, 6 assert(!settings.defaultResourceLoaded,
7 'settings.js run twice. You probably have an invalid import.'); 7 'settings.js run twice. You probably have an invalid import.');
8 /** Global defined when the main Settings script runs. */ 8 /** Global defined when the main Settings script runs. */
9 settings.defaultResourceLoaded = true; 9 settings.defaultResourceLoaded = true;
10 10
11 /** 11 /**
12 * @fileoverview 12 * @fileoverview
13 * 'cr-settings' is the main MD-Settings element, combining the UI and models. 13 * 'cr-settings' is the main MD-Settings element, combining the UI and models.
14 * 14 *
15 * Example: 15 * Example:
16 * 16 *
17 * <cr-settings></cr-settings> 17 * <cr-settings></cr-settings>
18 */ 18 */
19 Polymer({ 19 Polymer({
20 is: 'cr-settings', 20 is: 'cr-settings',
21 21
22 /** @override */
23 created: function() {
24 settings.initializeRouteFromUrl();
25 },
26
27 /** @override */
22 ready: function() { 28 ready: function() {
23 this.$.ui.directionDelegate = new settings.DirectionDelegateImpl; 29 this.$.ui.directionDelegate = new settings.DirectionDelegateImpl;
24 }, 30 },
25 }); 31 });
OLDNEW
« no previous file with comments | « chrome/browser/resources/settings/settings.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698