summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlukefromdc <[email protected]>2018-04-12 18:52:48 -0400
committerlukefromdc <[email protected]>2018-04-14 12:00:57 -0400
commit2e0a74d9458480966f2a87d1d66a58552a873300 (patch)
tree179bc2a71765e224892b53677adb5ee9b2937735
parentd3d057d4080e0dba6744a121d7eae5f50b92a278 (diff)
downloadmate-panel-2e0a74d9458480966f2a87d1d66a58552a873300.tar.bz2
mate-panel-2e0a74d9458480966f2a87d1d66a58552a873300.tar.xz
Theme: show applet handles on non-MATE themes
Fix https://github.com/mate-desktop/mate-panel/issues/758 Ensure that themes such as GNOME themes (e.g Adwaita) that do not explicitly support MATE show the drag handles for applets such as tray and window-list.
-rw-r--r--mate-panel/libmate-panel-applet-private/panel-applet-frame-dbus.c30
1 files changed, 30 insertions, 0 deletions
diff --git a/mate-panel/libmate-panel-applet-private/panel-applet-frame-dbus.c b/mate-panel/libmate-panel-applet-private/panel-applet-frame-dbus.c
index 006bdb0a..ce689312 100644
--- a/mate-panel/libmate-panel-applet-private/panel-applet-frame-dbus.c
+++ b/mate-panel/libmate-panel-applet-private/panel-applet-frame-dbus.c
@@ -262,6 +262,36 @@ mate_panel_applet_frame_dbus_change_background (MatePanelAppletFrame *frame,
g_free (bg_str);
}
+ GtkCssProvider *provider;
+ provider = gtk_css_provider_new ();
+ gtk_css_provider_load_from_data (provider,
+ "MatePanelAppletFrameDBus > MatePanelAppletFrameDBus { \n"
+ "border-style: solid; \n"
+ "border-width: 3px; \n"
+ "border-color: transparent; \n"
+ "background-repeat: no-repeat; \n"
+ "background-position: left; \n"
+ "background-image: linear-gradient(to bottom, \n"
+ "transparent, \n"
+ "transparent 20%, \n"
+ "alpha (#999999, 0.6) 21%, \n"
+ "alpha (#999999, 0.6) 29%, \n"
+ "transparent 30%, \n"
+ "transparent 45%, \n"
+ "alpha (#999999, 0.6) 46%, \n"
+ "alpha (#999999, 0.6) 54%, \n"
+ "transparent 55%, \n"
+ "transparent 70%, \n"
+ "alpha (#999999, 0.6) 71%, \n"
+ "alpha (#999999, 0.6) 79%, \n"
+ "transparent 80%, \n"
+ "transparent); \n"
+ "}",
+ -1, NULL);
+ gtk_style_context_add_provider (gtk_widget_get_style_context(GTK_WIDGET(frame)),
+ GTK_STYLE_PROVIDER (provider),
+ GTK_STYLE_PROVIDER_PRIORITY_FALLBACK);
+ g_object_unref (provider);
}
static void