Firefox doesn't use xdg for downloaded files

I have problem with firefox. When I downloading file for example with mime text/plain, firefox (from downloads window) opens it in wine notepad, but command xdg-mime query default text/plain returns exactly what i want: org.kde.kate.desktop. I already tried to add GTK_USE_PORTAL=1 env var to firefox by changing application but there is no result.

Annoying huh?
This ought to do it:
https://wiki.archlinux.org/title/Wine#Unregister_existing_Wine_file_associations

1 Like

Have you set this in about:config

widget.use-xdg-desktop-portal.file-picker
widget.widget.use-xdg-desktop-portal.mime-handler

from 2 to 1
?