From b6684bd302bd6794771eb2569b2b7b1539f8be09 Mon Sep 17 00:00:00 2001 From: lukefromdc Date: Thu, 10 Mar 2016 17:48:34 -0500 Subject: GTK 3.20-Prevent transparent panel on BG change The mate-custom-panel-background style class persists on the panel widget when resetting the panel BG to the system theme. It will overrride the panel system theme and turn the panel transparent with the new applet changes for some reason, so don't run panel_background_apply_css on GTK 3.20 builds. It's not needed to override t.he theme background for a custom background with the new code and GTK 3.20, and mate-panel-menu-bar is already present --- mate-panel/panel-widget.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/mate-panel/panel-widget.c b/mate-panel/panel-widget.c index 4830cdc8..54bbceb3 100644 --- a/mate-panel/panel-widget.c +++ b/mate-panel/panel-widget.c @@ -1650,10 +1650,11 @@ panel_widget_set_background_default_style (GtkWidget *widget) background = &PANEL_WIDGET (widget)->background; #if GTK_CHECK_VERSION (3, 19, 0) gtk_style_context_add_class(context,GTK_STYLE_CLASS_BACKGROUND); +#else + panel_background_apply_css (&PANEL_WIDGET (widget)->background, widget); #endif gtk_style_context_add_class(context,"gnome-panel-menu-bar"); - gtk_style_context_add_class(context,"mate-panel-menu-bar"); - panel_background_apply_css (&PANEL_WIDGET (widget)->background, widget); + gtk_style_context_add_class(context,"mate-panel-menu-bar"); gtk_style_context_get (context, state, "background-color", &bg_color, -- cgit v1.2.1