forked from AuroraMiddleware/gtk
gridview: Allow starting rubberband in empty space below last row
Rubberband does not work when initiated past the last row (warning is printed "Could not start rubberbanding: No item). Clamp y at the max height of the widgets in the gridview Fixes: #3462
This commit is contained in:
parent
c6f357e447
commit
1e9a36ffa8
@ -441,6 +441,7 @@ gtk_grid_view_get_position_from_allocation (GtkListBase *base,
|
||||
return FALSE;
|
||||
|
||||
n_items = gtk_list_base_get_n_items (base);
|
||||
along = CLAMP (along, 0, gtk_grid_view_compute_total_height (self) - 1);
|
||||
if (!gtk_grid_view_get_cell_at_y (self,
|
||||
along,
|
||||
&pos,
|
||||
|
Loading…
Reference in New Issue
Block a user