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

Unified Diff: chrome/browser/resources/settings/settings_page/main_page_behavior.js

Issue 2184893002: Settings Router Refactor: Remove route.page legacy property. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@0217-settings-refactor-settings-menu
Patch Set: fix contains issue. Created 4 years, 5 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/settings_page/main_page_behavior.js
diff --git a/chrome/browser/resources/settings/settings_page/main_page_behavior.js b/chrome/browser/resources/settings/settings_page/main_page_behavior.js
index 933a0ec4baab3a6cd5c57404141fed70b549de6c..852386f78c37e9ceec28fb565ba4fbb47228c13b 100644
--- a/chrome/browser/resources/settings/settings_page/main_page_behavior.js
+++ b/chrome/browser/resources/settings/settings_page/main_page_behavior.js
@@ -407,10 +407,9 @@ var RoutableBehaviorImpl = {
this.collapseSection(section);
}
- if (newRoute && newRoute.section &&
- this.$$('[data-page=' + newRoute.page + ']')) {
+ // Scrolls to the section if this main page contains the route's section.
+ if (newRoute && newRoute.section && this.getSection_(newRoute.section))
this.scrollToSection_();
- }
}
},

Powered by Google App Engine
This is Rietveld 408576698