Skip to content

Commit

Permalink
Fixed number of cols error after reload menus.
Browse files Browse the repository at this point in the history
After install/uninstall applications, each category of
applications display as one long line.
  • Loading branch information
yetist authored and raveit65 committed Jan 1, 2019
1 parent bdd05a6 commit 56c1867
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions libslab/app-resizer.c
Original file line number Diff line number Diff line change
Expand Up @@ -136,11 +136,11 @@ calculate_num_cols (AppResizer * resizer, gint avail_width)
GtkTable *table = GTK_TABLE (resizer->cached_tables_list->data);
GList *children = gtk_container_get_children (GTK_CONTAINER (table));
GtkWidget *table_element = GTK_WIDGET (children->data);
GtkAllocation allocation;
gint natural_width;
g_list_free (children);

gtk_widget_get_allocation (table_element, &allocation);
resizer->cached_element_width = allocation.width;
gtk_widget_get_preferred_width (table_element, NULL, &natural_width);
resizer->cached_element_width = natural_width;
resizer->cached_table_spacing = gtk_table_get_default_col_spacing (table);
}

Expand Down

0 comments on commit 56c1867

Please sign in to comment.