egui
egui copied to clipboard
Add a `released` event to widget Responses
Is your feature request related to a problem? Please describe.
I want to be able to drag and drop files inside a widget (like TextEdit for example) but the thing is currently there is no way to find out if the dragged files released inside a specific widget. I tried to use is_pointer_button_down_on
for this job, but this function only return true if button pressed/released when hovering on the widget (in other word if I drag a file at top of a widget then release mouse button to drop it, it dont receive any release event...), so I think a released
Response that return true when ever a button released at top of it would be good.
Describe the solution you'd like
Having a new function named released
that return true
when a button released at top of widget.
Describe alternatives you've considered
change is_pointer_button_down_on
functionality in order to return true in case that a button released at top of it (and not just when it first hovered on it) although I don't think its a good Idea... having a specific function would be better.
Additional context
()
is https://docs.rs/egui/latest/egui/struct.Response.html#method.drag_released what you want?
is https://docs.rs/egui/latest/egui/struct.Response.html#method.drag_released what you want?
no I was talking about system drag and drop (drag and drop a file from for example windows explorer to program), not the drag and drop inside program itself Here is the example but the thing is I want to be able to drop files in separate widget, like having multiple input widget that user can drag files into them separately.