Skip to content

Commit

Permalink
nemo-places-sidebar.c: Only register the special eject icon size
Browse files Browse the repository at this point in the history
once.

This is only needed once for the application.
  • Loading branch information
mtwebster committed Oct 22, 2024
1 parent b81ab12 commit 7eb062a
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/nemo-places-sidebar.c
Original file line number Diff line number Diff line change
Expand Up @@ -4111,11 +4111,6 @@ nemo_places_sidebar_init (NemoPlacesSidebar *sidebar)
GtkTreeSelection *selection;
GtkStyleContext *style_context;

gtk_icon_size_lookup (GTK_ICON_SIZE_MENU, &menu_icon_pixels, NULL);
EJECT_ICON_SIZE_NOT_HOVERED = gtk_icon_size_register ("menu-icon-size-small",
menu_icon_pixels - EJECT_ICON_SIZE_REDUCTION,
menu_icon_pixels - EJECT_ICON_SIZE_REDUCTION);

sidebar->action_manager = nemo_action_manager_new ();
sidebar->actions_changed_id = g_signal_connect_swapped (sidebar->action_manager,
"changed",
Expand Down Expand Up @@ -4489,6 +4484,11 @@ nemo_places_sidebar_class_init (NemoPlacesSidebarClass *class)

widget_class->style_set = nemo_places_sidebar_style_set;
widget_class->focus = nemo_places_sidebar_focus;

gtk_icon_size_lookup (GTK_ICON_SIZE_MENU, &menu_icon_pixels, NULL);
EJECT_ICON_SIZE_NOT_HOVERED = gtk_icon_size_register ("menu-icon-size-small",
menu_icon_pixels - EJECT_ICON_SIZE_REDUCTION,
menu_icon_pixels - EJECT_ICON_SIZE_REDUCTION);
}

static gboolean
Expand Down

0 comments on commit 7eb062a

Please sign in to comment.