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

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

Issue 2378933004: MD Settings: Skip unseen collapse animation (Closed)
Patch Set: work with about subpage too Created 4 years, 3 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
« no previous file with comments | « chrome/browser/resources/settings/settings_page/main_page_behavior.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/settings/settings_page/settings_section.js
diff --git a/chrome/browser/resources/settings/settings_page/settings_section.js b/chrome/browser/resources/settings/settings_page/settings_section.js
index 7833f39ba8b31db0bb47bbe0c20c88c58ed6ad2b..0fe5074c402cd2e6589aa2f8336bd544e71b4466 100644
--- a/chrome/browser/resources/settings/settings_page/settings_section.js
+++ b/chrome/browser/resources/settings/settings_page/settings_section.js
@@ -139,7 +139,10 @@ var SettingsSectionElement = Polymer({
return animation;
},
- /** @return {boolean} True if the section is currently expanded. */
+ /**
+ * @return {boolean} True if the section is currently expanded and we know
+ * what the collapsed height should be.
+ */
canAnimateCollapse: function() {
return this.classList.contains('expanded') && this.clientHeight > 0 &&
!Number.isNaN(this.collapsedHeight_);
« no previous file with comments | « chrome/browser/resources/settings/settings_page/main_page_behavior.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698