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

Unified Diff: chrome/browser/resources/settings/device_page/device_page.js

Issue 2210933004: Settings Router Refactor: Kill settings-router. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix merge 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/resources/settings/device_page/device_page.js
diff --git a/chrome/browser/resources/settings/device_page/device_page.js b/chrome/browser/resources/settings/device_page/device_page.js
index c416e15d41fbbd9bf275c9aea3bcb8dad1022837..9e4efee35b38511ea4d1b68f61f8fdea7d5f358d 100644
--- a/chrome/browser/resources/settings/device_page/device_page.js
+++ b/chrome/browser/resources/settings/device_page/device_page.js
@@ -12,16 +12,10 @@ Polymer({
behaviors: [
I18nBehavior,
WebUIListenerBehavior,
+ settings.RouteObserverBehavior,
],
properties: {
- /** The current active route. */
- currentRoute: {
- type: Object,
- notify: true,
- observers: 'currentRouteChanged_',
- },
-
/** Preferences state. */
prefs: {
type: Object,
@@ -119,8 +113,8 @@ Polymer({
settings.navigateTo(settings.Route.DISPLAY);
},
- /** @private */
- currentRouteChanged_: function() {
+ /** @protected */
+ currentRouteChanged: function() {
this.checkPointerSubpage_();
},
@@ -140,7 +134,7 @@ Polymer({
*/
checkPointerSubpage_: function() {
if (!this.hasMouse_ && !this.hasTouchpad_ &&
- this.currentRoute == settings.Route.POINTERS) {
+ settings.getCurrentRoute() == settings.Route.POINTERS) {
this.$.pages.fire('subpage-back');
}
},

Powered by Google App Engine
This is Rietveld 408576698