Skip to content

Commit cc33d66

Browse files
lukefromdcraveit65
authored and
raveit65
committed
Tray: Fix too-wide icon spacing after mate-polkit has been used w sni
Note that vertical and horizontal panels require different options in the grid, as "homogenous" is needed in rows for horizontal panels and columns in vertical panels to prevent icon rendering problems including icons growing without limit when the tray is moved from a horizontal to a vertical panel
1 parent bab2d5a commit cc33d66

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

applets/notification_area/na-grid.c

+5
Original file line numberDiff line numberDiff line change
@@ -145,13 +145,17 @@ refresh_grid (NaGrid *self)
145145

146146
if (orientation == GTK_ORIENTATION_HORIZONTAL)
147147
{
148+
gtk_grid_set_row_homogeneous (GTK_GRID (self), TRUE);
149+
gtk_grid_set_column_homogeneous (GTK_GRID (self), FALSE);
148150
rows = MAX (1, allocation.height / self->min_icon_size);
149151
cols = MAX (1, length / rows);
150152
if (length % rows)
151153
cols++;
152154
}
153155
else
154156
{
157+
gtk_grid_set_row_homogeneous (GTK_GRID (self), FALSE);
158+
gtk_grid_set_column_homogeneous (GTK_GRID (self), TRUE);
155159
cols = MAX (1, allocation.width / self->min_icon_size);
156160
rows = MAX (1, length / cols);
157161
if (length % cols)
@@ -243,6 +247,7 @@ na_grid_init (NaGrid *self)
243247

244248
gtk_grid_set_row_homogeneous (GTK_GRID (self), TRUE);
245249
gtk_grid_set_column_homogeneous (GTK_GRID (self), TRUE);
250+
246251
}
247252

248253
static void

0 commit comments

Comments
 (0)