summaryrefslogtreecommitdiff
path: root/applets
diff options
context:
space:
mode:
authorWolfgang Ulbrich <[email protected]>2016-02-11 07:49:33 +0100
committerWolfgang Ulbrich <[email protected]>2016-02-12 07:04:31 +0100
commit764b55c2f19cf4d4d27c7c0ade6c3cfb67292188 (patch)
treeccaf5ec62220996f1fa750eba0ccb6edd12b0315 /applets
parent4932ed52b70b540bd58e6405550ea2e758c1d003 (diff)
downloadmate-panel-764b55c2f19cf4d4d27c7c0ade6c3cfb67292188.tar.bz2
mate-panel-764b55c2f19cf4d4d27c7c0ade6c3cfb67292188.tar.xz
GTK+-3.20 notification-area: remove deprecated style properties
Those properties don't work anymore in themes and spam only the logs. taken from: https://git.gnome.org/browse/gnome-panel/commit/?id=e55b759
Diffstat (limited to 'applets')
-rw-r--r--applets/notification_area/main.c17
1 files changed, 14 insertions, 3 deletions
diff --git a/applets/notification_area/main.c b/applets/notification_area/main.c
index 448f9e39..557488d3 100644
--- a/applets/notification_area/main.c
+++ b/applets/notification_area/main.c
@@ -282,10 +282,13 @@ na_tray_applet_change_orient (MatePanelApplet *panel_applet,
get_gtk_orientation_from_applet_orient (orient));
}
+#if GTK_CHECK_VERSION (3, 0, 0)
+#if GTK_CHECK_VERSION (3, 19, 0)
+/* deprecated with gtk+-3.19.0 */
+#else
static inline void
force_no_focus_padding (GtkWidget *widget)
{
-#if GTK_CHECK_VERSION (3, 0, 0)
GtkCssProvider *provider;
provider = gtk_css_provider_new ();
@@ -299,7 +302,12 @@ force_no_focus_padding (GtkWidget *widget)
GTK_STYLE_PROVIDER (provider),
GTK_STYLE_PROVIDER_PRIORITY_APPLICATION);
g_object_unref (provider);
+}
+#endif
#else
+static inline void
+force_no_focus_padding (GtkWidget *widget)
+{
gtk_rc_parse_string ("\n"
" style \"na-tray-style\"\n"
" {\n"
@@ -309,8 +317,8 @@ force_no_focus_padding (GtkWidget *widget)
"\n"
" class \"NaTrayApplet\" style \"na-tray-style\"\n"
"\n");
-#endif
}
+#endif
static void
na_tray_applet_class_init (NaTrayAppletClass *class)
@@ -378,8 +386,11 @@ na_tray_applet_init (NaTrayApplet *applet)
mate_panel_applet_set_background_widget (MATE_PANEL_APPLET (applet),
GTK_WIDGET (applet));
#endif
-
+#if GTK_CHECK_VERSION (3, 19, 0)
+/* deprecated with gtk+-3.19.0 */
+#else
force_no_focus_padding (GTK_WIDGET (applet));
+#endif
}
static gboolean