From b179cad057ff83ccc05b1a346764cb6e0e8ac655 Mon Sep 17 00:00:00 2001 From: Victor Kareh Date: Fri, 27 Jul 2018 14:08:09 -0400 Subject: applets: Guard against GTK scale-factor fixes on GtkSocket --- applets/notification_area/system-tray/na-tray-child.c | 6 +++--- applets/wncklet/window-list.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) (limited to 'applets') diff --git a/applets/notification_area/system-tray/na-tray-child.c b/applets/notification_area/system-tray/na-tray-child.c index 4bb4ecf2..c8f022a3 100644 --- a/applets/notification_area/system-tray/na-tray-child.c +++ b/applets/notification_area/system-tray/na-tray-child.c @@ -115,11 +115,11 @@ na_tray_child_style_set (GtkWidget *widget, */ } -#if !GTK_CHECK_VERSION (3, 23, 0) +#if !GTK_CHECK_VERSION (3, 22, 31) static void na_tray_child_get_preferred_width (GtkWidget *widget, gint *minimal_width, - gint *natural_width) + gint *natural_width) { gint scale; scale = gtk_widget_get_scale_factor (widget); @@ -384,7 +384,7 @@ na_tray_child_class_init (NaTrayChildClass *klass) widget_class->style_set = na_tray_child_style_set; widget_class->realize = na_tray_child_realize; -#if !GTK_CHECK_VERSION (3, 23, 0) +#if !GTK_CHECK_VERSION (3, 22, 31) widget_class->get_preferred_width = na_tray_child_get_preferred_width; widget_class->get_preferred_height = na_tray_child_get_preferred_height; #endif diff --git a/applets/wncklet/window-list.c b/applets/wncklet/window-list.c index f6055e43..35b87c74 100644 --- a/applets/wncklet/window-list.c +++ b/applets/wncklet/window-list.c @@ -42,7 +42,7 @@ typedef struct { GtkOrientation orientation; int size; -#ifndef WNCKLET_INPROCESS +#if !defined(WNCKLET_INPROCESS) && !GTK_CHECK_VERSION (3, 22, 31) gboolean needs_hints; #endif @@ -322,7 +322,7 @@ static void applet_size_allocate(GtkWidget *widget, GtkAllocation *allocation, T g_assert(len % 2 == 0); -#ifndef WNCKLET_INPROCESS +#if !defined(WNCKLET_INPROCESS) && !GTK_CHECK_VERSION (3, 22, 31) /* HACK: When loading the WnckTasklist initially, it reports size hints as though there were * no elements in the Tasklist. This causes a rendering issue when built out-of-process in * HiDPI displays. We keep a flag to skip size hinting until WnckTasklist has something to @@ -427,7 +427,7 @@ gboolean window_list_applet_fill(MatePanelApplet* applet) tasklist->size = mate_panel_applet_get_size(applet); -#ifndef WNCKLET_INPROCESS +#if !defined(WNCKLET_INPROCESS) && !GTK_CHECK_VERSION (3, 22, 31) tasklist->needs_hints = FALSE; #endif -- cgit v1.2.1