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

Unified Diff: chrome/browser/resources/ntp4/other_sessions.js

Issue 10389016: Use hidden attribute rather the 'display: none' for hiding menus. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Prevent FoUC with menus, using Evan's suggestion. Created 8 years, 7 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 | « no previous file | chrome/browser/resources/shared/css/menu.css » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/ntp4/other_sessions.js
diff --git a/chrome/browser/resources/ntp4/other_sessions.js b/chrome/browser/resources/ntp4/other_sessions.js
index 5e38764bdb7bf369c32ba4276b8e2040222189be..1a0f60d9a221e9cc10fa98e1d55349b1165562b3 100644
--- a/chrome/browser/resources/ntp4/other_sessions.js
+++ b/chrome/browser/resources/ntp4/other_sessions.js
@@ -55,7 +55,6 @@ cr.define('ntp', function() {
// Create the context menu that appears when the user right clicks
// on a device name.
this.deviceContextMenu_ = DeviceContextMenuController.getInstance().menu;
- this.deviceContextMenu_.style.display = 'none';
document.body.appendChild(this.deviceContextMenu_);
this.promoMessage_ = $('other-sessions-promo-template').cloneNode(true);
@@ -107,7 +106,7 @@ cr.define('ntp', function() {
*/
hideMenu: function() {
// Don't hide if the device context menu is currently showing.
- if (this.deviceContextMenu_.style.display == 'none')
+ if (this.deviceContextMenu_.hidden)
MenuButton.prototype.hideMenu.call(this);
},
« no previous file with comments | « no previous file | chrome/browser/resources/shared/css/menu.css » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698