From 445038545870241315bdfd4465c815fe388e575e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20M=C3=BCllner?= Date: Tue, 8 Feb 2011 19:46:05 +0100 Subject: [PATCH] panel-button: Set ':active' pseudo class when menu is open Commit c86a977564e5 removed :pressed from the list of styles which highlight panel buttons, so the button highlight is now lost when mousing over menu items. This is not the behavior we want, the buttons should keep their highlight while being "active". Rather than adding back the pseudo class to the CSS, let buttons use the :active pseudo class when the menu is open, which makes more sense than :pressed anyway. --- js/ui/panelMenu.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/js/ui/panelMenu.js b/js/ui/panelMenu.js index 0b3ce939c..6248264e3 100644 --- a/js/ui/panelMenu.js +++ b/js/ui/panelMenu.js @@ -48,9 +48,9 @@ Button.prototype = { _onOpenStateChanged: function(menu, open) { if (open) - this.actor.add_style_pseudo_class('pressed'); + this.actor.add_style_pseudo_class('active'); else - this.actor.remove_style_pseudo_class('pressed'); + this.actor.remove_style_pseudo_class('active'); } };