Open anlumo opened 4 months ago
If you have a specific use case like this you might want to look at the lower level BaseDraggableWidget
, which lets you build the entire DragConfiguration
independent of widgets.
Thank you for the response! Unfortunately, the documentation for this class is rather lackluster, so it's taking a while to understand how to use it.
I've implemented a sliver-based scrollable grid view with a selection, and when dragging items all selected ones have to be dragged along, including the ones that are scrolled outside of the currently visible view.
It appears that super_drag_and_drop doesn't support this use case. Drag items have to be widgets, but offscreen items aren't part of the widget tree, and so there is no widget for them. I can provide another widget for the drag item via DragItemWidget's
dragBuilder
, but I'm running into problems there:Opacity(opacity: 0, ...)
widget, the drag image also is invisible.Offstage
widget, the drag image also is invisible.I couldn't find a way to make this work, am I missing something?