Skip to content
Browse files
canvas-container: listen to scale factor to invalidate icons
This is one of the condition that needs to trigger an invalidation to
recompute layout at the correct size.

origin commit:
  • Loading branch information
llandwerlin-intel authored and raveit65 committed Apr 5, 2018
1 parent 52d44de commit 35c4dc6021f36a5fc7df94b0332c7e5d6fa00d0a
Showing with 12 additions and 0 deletions.
  1. +12 −0 libcaja-private/caja-icon-container.c
@@ -6621,6 +6621,15 @@ handle_focus_out_event (GtkWidget *widget, GdkEventFocus *event, gpointer user_d
return FALSE;

static void
handle_scale_factor_changed (GObject *object,
GParamSpec *pspec,
gpointer user_data)
invalidate_labels (CAJA_ICON_CONTAINER (object));
caja_icon_container_request_update_all (CAJA_ICON_CONTAINER (object));

static int text_ellipsis_limits[CAJA_ZOOM_LEVEL_N_ENTRIES];
static int desktop_text_ellipsis_limit;
@@ -6743,6 +6752,9 @@ caja_icon_container_init (CajaIconContainer *container)
g_signal_connect (container, "focus-out-event",
G_CALLBACK (handle_focus_out_event), NULL);

g_signal_connect (container, "notify::scale-factor",
G_CALLBACK (handle_scale_factor_changed), NULL);

eel_background_set_use_base (background, TRUE);

if (!setup_prefs)

0 comments on commit 35c4dc6

Please sign in to comment.