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

Side by Side Diff: chrome/browser/resources/help/help_page.js

Issue 1530773002: Revert of Fix flaky logo spin animation restart logic (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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 | « no previous file | 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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.define('help', function() { 5 cr.define('help', function() {
6 var Page = cr.ui.pageManager.Page; 6 var Page = cr.ui.pageManager.Page;
7 var PageManager = cr.ui.pageManager.PageManager; 7 var PageManager = cr.ui.pageManager.PageManager;
8 8
9 /** 9 /**
10 * Encapsulated handling of the About page. Called 'help' internally to avoid 10 * Encapsulated handling of the About page. Called 'help' internally to avoid
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
158 158
159 // Unhide the regulatory label if/when the image loads. 159 // Unhide the regulatory label if/when the image loads.
160 $('regulatory-label').onload = function() { 160 $('regulatory-label').onload = function() {
161 $('regulatory-label-container').hidden = false; 161 $('regulatory-label-container').hidden = false;
162 }; 162 };
163 } 163 }
164 164
165 var logo = $('product-logo'); 165 var logo = $('product-logo');
166 logo.onclick = function(e) { 166 logo.onclick = function(e) {
167 logo.classList.remove('spin'); 167 logo.classList.remove('spin');
168 // Force a style recalc that cancels the animation specified by "spin". 168 setTimeout(function() { logo.classList.add('spin'); }, 0);
169 getComputedStyle(logo).animationName;
170 logo.classList.add('spin');
171 }; 169 };
172 170
173 // Attempt to update. 171 // Attempt to update.
174 chrome.send('onPageLoaded'); 172 chrome.send('onPageLoaded');
175 }, 173 },
176 174
177 /** @override */ 175 /** @override */
178 didClosePage: function() { 176 didClosePage: function() {
179 this.setMoreInfoVisible_(false); 177 this.setMoreInfoVisible_(false);
180 }, 178 },
(...skipping 492 matching lines...) Expand 10 before | Expand all | Expand 10 after
673 HelpPage.setRegulatoryLabelText = function(text) { 671 HelpPage.setRegulatoryLabelText = function(text) {
674 assert(cr.isChromeOS); 672 assert(cr.isChromeOS);
675 HelpPage.getInstance().setRegulatoryLabelText_(text); 673 HelpPage.getInstance().setRegulatoryLabelText_(text);
676 }; 674 };
677 675
678 // Export 676 // Export
679 return { 677 return {
680 HelpPage: HelpPage 678 HelpPage: HelpPage
681 }; 679 };
682 }); 680 });
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698