dioxus icon indicating copy to clipboard operation
dioxus copied to clipboard

Dropping files doesn't work on Wayland

Open breard-r opened this issue 1 year ago • 0 comments

Problem

When using a Wayland-based WM/DE (Hyprland, GNOME 3,…), dropping files (ondrop) always return an empty list of files. The same machine, when using an X-based desktop environment (Cinnamon,…), doesn't have this issue.

Steps To Reproduce

Steps to reproduce the behavior:

  • Use any Wayland-based WM or DE
  • cargo r --example file_upload
  • Click on Choose Files and select a file: it works
  • Click on Clear Files
  • Drag and drop the same file on the drop area: it does not work

Expected behavior

Dragging and dropping a file in the drop area should have the same effect as selecting it using the Choose Files button.

Environment:

  • Dioxus version: v0.5.6
  • Rust version: stable (v1.82.0)
  • OS info: ArchLinux with Hyprland // Ubuntu 24.04.1 with GNOME 3
  • App platform: desktop

Notes

I noticed the idea to switch from tao to winit #2706

However, winit seems to have the same issue: rust-windowing/winit#720 rust-windowing/winit#1881

breard-r avatar Oct 25 '24 11:10 breard-r