Closed daydream123 closed 8 months ago
感觉是线程阻塞问题,你使用tokio::spawn(async{show_dialog()})或者thread::spawn(||{show_dialog()})试一下 我感觉是你调用pick_file之后,会等待你去选择文件,而slint中的渲染由于选择文件被阻断了或者slint的渲染影响了pick_file的线程
感觉是线程阻塞问题,你使用tokio::spawn(async{show_dialog()})或者thread::spawn(||{show_dialog()})试一下 我感觉是你调用pick_file之后,会等待你去选择文件,而slint中的渲染由于选择文件被阻断了或者slint的渲染影响了pick_file的线程
I tested, you're right, but other folders like Documents
, Images
, Videos
can show files..., very strange!
slint version: 4.1
I tried to integrate
native-dialog/0.7.0
into my slint project to allow user pick file from local disk, and I found that I cannot pick any file underC:\Users\[User]\Downloads
, the file dialog showsWorking on it...
always. ThenI tried anther thirdpart lib calledrfd/0.14.0
, it has the same result, I tried to run their examples, they work without problem, I don't known why it cannot work in my slint project:I created a simple demo project, blow is my test code: